How to set up Visual Studio Code for Executing and Debugging C Programs | Tutorial

แชร์
ฝัง
  • เผยแพร่เมื่อ 28 ก.ย. 2024

ความคิดเห็น • 432

  • @bekzodhakimov4573
    @bekzodhakimov4573 2 ปีที่แล้ว +17

    My man, i was trying to fix this debugging and executing c program issue for like whole 1 day. I tried many things other youtubers told. all ended with more issues. I am new to programming, i dont know what i was doing. This video fixed all. Thanks. I subscribed

  • @snehanshourya3850
    @snehanshourya3850 2 ปีที่แล้ว +4

    Thank you so much, before watching your video I spent 2 days reading here and there on how to debug. All articles are so full of bs! I was so frustrated, I downloaded Visual Studio Community but couldn't get it to work either. But you solved the problem in 20 mins! Thank you from bottom of my heart.

  • @atticusfoust6389
    @atticusfoust6389 2 ปีที่แล้ว +2

    If you're getting a gdb error, run sudo apt-get install gdb
    Only video I've seen that explains what is needed and more. Thank you sir!

  • @thaboleroytheosmketsu8864
    @thaboleroytheosmketsu8864 3 ปีที่แล้ว +11

    I am getting an error message which says && is not a valid statement separator in this version.

    • @aayushi8784
      @aayushi8784 3 ปีที่แล้ว +2

      @Anirban Kopty how to upgrade this to 7.1 ? (i am getting same error as mentioned in above comment)

    • @alameen2784
      @alameen2784 3 ปีที่แล้ว +2

      @Anirban Kopty Thanks it worked!

    • @RandMV
      @RandMV 3 ปีที่แล้ว

      @Anirban Kopty Thanksss it workeeeddd!!!!

    • @toressuarez
      @toressuarez 3 ปีที่แล้ว

      @Anirban Kopty thanks dude, your recommendation worked

    • @anonimatejust5349
      @anonimatejust5349 2 ปีที่แล้ว

      @@aayushi8784 what is it to update? can't follow through. tia

  • @mohammedimran6707
    @mohammedimran6707 2 ปีที่แล้ว +21

    when I tried to build an executable file,I got an error"gcc.exe: fatal error: cannot execute 'cc1': CreateProcess: No such file or directory'' can you explain?

    • @pinsie0524
      @pinsie0524 2 ปีที่แล้ว +2

      Hi Imran. I had the same error too. Then I realised that you should name your file 'HelloWorld.C' without any spacing between the 'Hello' and 'World'. Worked for me and hope that it helps.

    • @dsniloy9289
      @dsniloy9289 ปีที่แล้ว +1

      I tried but it still shows cc1.exe: fatal error(no such file or directory)

  • @thatguy8278
    @thatguy8278 3 ปีที่แล้ว +30

    To execute Hello World in the Terminal I had to use ./"hello wrold"

  • @16anurag9
    @16anurag9 2 ปีที่แล้ว +3

    + ~~
    The token '&&' is not a valid statement separator in this version.
    + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : InvalidEndOfLine could you help please

    • @adilch9793
      @adilch9793 2 ปีที่แล้ว +1

      replace && with ;

    • @letdoit1222
      @letdoit1222 11 หลายเดือนก่อน

      @@adilch9793 na man it's not happening 😭

  • @rockymountainfacet5958
    @rockymountainfacet5958 ปีที่แล้ว +1

    You are my hero. I have been trying to fix my vs code's .json error for a wile. I actually started using a different program because of it. I like vscode for python and wanted to be able to use c++ on it. but it was giving me .json errors. anyways you fixed it for me with this video. Thank you so much. I would give you a big hug if I could. God bless

  • @rogerpark3221
    @rogerpark3221 2 หลายเดือนก่อน +1

    Thanks for the info. was able to install the two programs successfully

    • @LearningLad
      @LearningLad  2 หลายเดือนก่อน

      Most welcome :)

  • @fatihcay3387
    @fatihcay3387 2 ปีที่แล้ว +1

    The most video that i have ever seen about vsc debugging , thanks!!

    • @LearningLad
      @LearningLad  2 ปีที่แล้ว

      Glad it was helpful!

  • @MarinaPopelov-df7pc
    @MarinaPopelov-df7pc ปีที่แล้ว +3

    Best tutorial ever! I was already desperate when I found it and it really helped me, huge thank you!
    Also, maybe someone can help me with one issue, despite placing the " \" " (17:54), I still got problems with the spaces when parsing the paths, maybe someone knows what can it be?

  • @surxo-dk3xi
    @surxo-dk3xi 3 ปีที่แล้ว +8

    Thanks for these tutorials! Really helpful.

  • @chanchalsrajanagrawal7545
    @chanchalsrajanagrawal7545 2 ปีที่แล้ว +2

    The best ever video for setup of vs code
    I have ever seen
    😘🔥🔥🔥
    Much appreciated😊😊

  • @apeowo
    @apeowo 2 ปีที่แล้ว +1

    Hello sir i have a problem it says this when i to run the exe from the terminal This version of C:\Users\MARVE\Documents\My Programs\Hello World\Hello World.exe is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher.

    • @l_or_enzociotola8298
      @l_or_enzociotola8298 2 ปีที่แล้ว +1

      check if ur system is 32 or 64 bit

    • @apeowo
      @apeowo 2 ปีที่แล้ว

      @@l_or_enzociotola8298 it is 64 bit

    • @l_or_enzociotola8298
      @l_or_enzociotola8298 2 ปีที่แล้ว +1

      @@apeowo check if u have installed mingw 32 or 64 bit

  • @wojciechpason4222
    @wojciechpason4222 2 ปีที่แล้ว +2

    been just under a year and this tutorial is already outdated. can someone please help me, i got this error: The token '&&' is not a valid statement separator in this version.
    i don't have a clue what to do to fix it

    • @LearningLad
      @LearningLad  2 ปีที่แล้ว +1

      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

    • @kyrylosirenko2155
      @kyrylosirenko2155 2 หลายเดือนก่อน

      @@LearningLad This helps, however, it launches cmd every time before actually working in the vs code terminal, which is annoying. Is there another fix?

  • @AdmanAbid
    @AdmanAbid ปีที่แล้ว +2

    When I run the debugger the outputs don't show in my terminal, similarly I can't give any inputs. But everything else runs just fine. Does anyone know how to fix it?

    • @lwh4inluv973
      @lwh4inluv973 ปีที่แล้ว +1

      yeah, me too, i just could type the age and not thing happen, but it seemed still happening

    • @malcolmbrt
      @malcolmbrt 2 หลายเดือนก่อน

      I have the same problem, did you find a solution?

  • @amolmagar6468
    @amolmagar6468 3 ปีที่แล้ว +4

    Thanks for every single reply and giving so much time 🙏😍

  • @hrushikartejak3829
    @hrushikartejak3829 3 ปีที่แล้ว +3

    After I started the debugger, it shows all those blue lines and some yellow lines, but in the terminal, it does not show "Enter your age". So, I am unable to enter any input. From this point onwards, nothing happens.
    Please help me with this problem

    • @pierfrancescoemiliani3170
      @pierfrancescoemiliani3170 3 ปีที่แล้ว +1

      I have the same problem. After entering in the terminal "Hello World" the output is Hello World and i don't know why. If someone is able to solve it please help

  • @twotwo5579
    @twotwo5579 2 ปีที่แล้ว +4

    Wow, u are amazing! You explain it very details. Thank you.

  • @alexagomez111
    @alexagomez111 3 ปีที่แล้ว +9

    Thank you very much for your tutorials! My only issue is when I try to run and debug after selecting C++ (GDB/LLDB) I doesn't give the tasks to choose from, instead I get an empty launch.json with no configurations on it. Do you have any solution for this? Thank you.

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      Have you installed c c++ extension?

    • @VorT6
      @VorT6 3 ปีที่แล้ว +1

      Had to manually write and edit the json. Had the same issue. But @LearningLad did a very nice tutorial here! Kudos from me for starting point.

    • @yogesh2395
      @yogesh2395 3 ปีที่แล้ว +3

      @@VorT6 hey bro can you pl tell the hole thing which you have typped in json

    • @m3ndez435
      @m3ndez435 2 ปีที่แล้ว +2

      delete the whole launch.json file, and a new one will be generated when u do what he says

    • @040asysyaffakhoirunnisa6
      @040asysyaffakhoirunnisa6 2 ปีที่แล้ว +1

      I have the sae issues. Could somebody help me please? I already installed the C/C++ extension

  • @yifeizhou1983
    @yifeizhou1983 3 ปีที่แล้ว +2

    My debugger works, but a problem appears every time. It says "property console is not allowed" for the launch.json file. It doesn't seem to impact anything at the moment, but do you know what I can do to fix it?

  • @Missing2ndgear
    @Missing2ndgear 3 ปีที่แล้ว +2

    Thank you for making this video, it helped me so much in setting up the c programming in visual studio code.

  • @abhisheksinha2167
    @abhisheksinha2167 3 ปีที่แล้ว +1

    hey i am getting a error . i.e Unable to start debugging . the value ofmiDebuggerPath is invalid .....plz help .. m stuck

  • @oken6325
    @oken6325 11 หลายเดือนก่อน +1

    Is there an updated version of this tutorial? I'm using it in 2023 and nothing is going according to plan 😂

  • @uchennagodfrey8343
    @uchennagodfrey8343 ปีที่แล้ว +1

    Hello,
    I'm new to learning C language
    Should I follow directly from top to bottom on the playlist? cos some videos are of different years also the numbering on video names.
    Please direct me

    • @LearningLad
      @LearningLad  ปีที่แล้ว +1

      yes
      follow the tutorials as they are in the playlist

    • @uchennagodfrey8343
      @uchennagodfrey8343 ปีที่แล้ว +1

      @@LearningLad Okay, thanks alot sir🙌
      Learning alot tho just a beginner.
      Love the way you teach.
      Thanks again.

    • @LearningLad
      @LearningLad  ปีที่แล้ว

      All the best :)

  • @lucas-jg2ce
    @lucas-jg2ce 2 ปีที่แล้ว +3

    Man you always fix everything, thank you so much!

  • @t.e.d9875
    @t.e.d9875 ปีที่แล้ว

    when i go to select a build task the gcc.exe doesnt show up? this all started with me trying to fix an error or "Launch: Program does not exist. any help please??

  • @pethupk9619
    @pethupk9619 3 ปีที่แล้ว +1

    Starting build...
    C:\msys64\mingw64\bin\gcc.exe -g3 -wall "F:\CODING PK\C\Programs\.vscode\tasks.json" -o "F:\CODING PK\C\Programs\.vscode\tasks.exe"
    gcc.exe: error: unrecognized command-line option '-wall'; did you mean '-Wall'?
    Build finished with error(s).
    The terminal process failed to launch (exit code: -1).
    showing error like this in tasks.json

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      Wall w is capital

    • @pethupk9619
      @pethupk9619 3 ปีที่แล้ว

      @@LearningLad Thankyou Bro

  • @pierfrancescoemiliani3170
    @pierfrancescoemiliani3170 3 ปีที่แล้ว +3

    I have an issue with the other way to run the program at minute 19:07 . The error is that && is not valid in the version I installed, how to get over this problem?

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

  • @prasadwakle2462
    @prasadwakle2462 3 ปีที่แล้ว +2

    If the code runner extension is installed is it still necessary to set up build task?

  • @joaquinmucino3210
    @joaquinmucino3210 3 ปีที่แล้ว +4

    Excuse me can you help me with this error??
    The token '&&' is not a valid statement separator in this version
    i actually try the -and it does not work
    thaks

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      pls provide the contents of your tasks.json file
      ( that particular line is enough )

    • @joaquinmucino3210
      @joaquinmucino3210 3 ปีที่แล้ว

      @@LearningLad Actually I dont know what happened. At firstplace it does not work, but latter, about a few minutes, everything was ok see
      {
      "version": "2.0.0",
      "tasks": [
      {
      "type": "cppbuild",
      "label": "C/C++: gcc.exe build active file",
      "command": "C:\\msys64\\mingw64\\bin\\gcc.exe",
      "args": [
      "-g3",
      "-Wall",
      "${file}",
      "-o",
      "${fileDirname}\\${fileBasenameNoExtension}.exe"
      ],
      "options": {
      "cwd": "C:\\msys64\\mingw64\\bin"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "group": {
      "kind": "build",
      "isDefault": true
      },
      "detail": "compiler: C:\\msys64\\mingw64\\bin\\gcc.exe"
      },
      {
      "type": "shell",
      "label": "Run this C Program",
      "command": "C:\\msys64\\mingw64\\bin\\gcc.exe -g3 -Wall ${file} -o ${fileDirname}\\${fileBasenameNoExtension}.exe ;${fileDirname}\\${fileBasenameNoExtension}.exe",

      "options": {
      "cwd": "C:\\msys64\\mingw64\\bin"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "detail": "compiler: C:\\msys64\\mingw64\\bin\\gcc.exe"
      }
      ]
      }

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +3

      i have made some modifications
      checkout
      {
      "version": "2.0.0",
      "tasks": [
      {
      "type": "cppbuild",
      "label": "C/C++: gcc.exe build active file",
      "command": "C:\\msys64\\mingw64\\bin\\gcc.exe",
      "args": [
      "-g3",
      "-Wall",
      "${file}",
      "-o",
      "${fileDirname}\\${fileBasenameNoExtension}.exe"
      ],
      "options": {
      "cwd": "C:\\msys64\\mingw64\\bin"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "group": {
      "kind": "build",
      "isDefault": true
      },
      "detail": "compiler: C:\\msys64\\mingw64\\bin\\gcc.exe"
      },
      {
      "type": "shell",
      "label": "Run this C Program",
      "command": "C:\\msys64\\mingw64\\bin\\gcc.exe -g3 -Wall \"${file}\" -o \"${fileDirname}\\${fileBasenameNoExtension}.exe\" &&\"${fileDirname}\\${fileBasenameNoExtension}.exe\"",
      "options": {
      "cwd": "C:\\msys64\\mingw64\\bin"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "detail": "compiler: C:\\msys64\\mingw64\\bin\\gcc.exe"
      }
      ]
      }

    • @shockthegames660
      @shockthegames660 3 ปีที่แล้ว

      i have joaquin same problem soo for the moment im building and running from the powershell

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      sorry for late reply.
      didn't see your comment
      solution is :
      In vs code
      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

  • @simo4win55
    @simo4win55 ปีที่แล้ว +1

    i have i problem, everythings work, it compile and debug, BUT there is a huge problem, i can use breakpopints, so i know he is debugging, but doesn't run the program in the terminal, so i can't put things in the scanf(), so the debug crash when he see it, because has no value in input,
    TY for everyone who will help me!

    • @zetsu5648
      @zetsu5648 หลายเดือนก่อน +1

      im having the same issue did u find the solution? thanks

  • @mushfiqaraf5079
    @mushfiqaraf5079 3 ปีที่แล้ว +1

    Hey Mr. Anil, can you plz say which recorder do you use and which software for editing these videos, plz reply 🙏🙏

  • @lucasjoseserena2473
    @lucasjoseserena2473 2 ปีที่แล้ว +1

    Thank you very much for the detailed information. You got a new suscriber :)

  • @kpakfar
    @kpakfar ปีที่แล้ว

    How can I do the same process for multiple files C project?

  • @educatech8450
    @educatech8450 2 ปีที่แล้ว +1

    At line:1 char:141
    + ... c -o c:\Users\LENOVO\3D Objects\C\Programs\Hello World.exe &&c:\Users ...
    + ~~
    The token '&&' is not a valid statement separator in this version.
    + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : InvalidEndOfLine
    Bro, i'm getting this error, aftr clicking "Run Task", and then "Run This C Program",
    Please help me bro, what i have to do

    • @manutv08
      @manutv08 2 ปีที่แล้ว

      It's because you're in PowerShell, try running it in CMD

    • @l_or_enzociotola8298
      @l_or_enzociotola8298 2 ปีที่แล้ว

      replace && with ;

    • @educatech8450
      @educatech8450 2 ปีที่แล้ว

      @@manutv08 i didn't understand bro... can you say more precisely, and tell what to do now

    • @educatech8450
      @educatech8450 2 ปีที่แล้ว

      @@l_or_enzociotola8298 bro, it is also giving a error

    • @manutv08
      @manutv08 2 ปีที่แล้ว

      @@educatech8450 You have to select your default terminal as Command Prompt.
      You can do this by pressing F1 in VS Code and typing/selecting "Terminal: Select Default Profile" (or Terminal: Select Default Shell in older VSCode versions). Then a list will appear, from that select "Command Prompt".

  • @Soider3
    @Soider3 2 ปีที่แล้ว +1

    19:28 -> "terminated with exit code: 1" 😭😭

  • @naiwritmullick9918
    @naiwritmullick9918 3 ปีที่แล้ว +2

    Is it really necessary to execute the program via the terminal? I am referring to your older videos and according to that clip we can simply run the code and get the output.

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +3

      No, it is not necessary.
      Just wanted to show how to use the terminal to run the program ( for those who don't want to use the code runner extension).

  • @unknwonknight9864
    @unknwonknight9864 2 ปีที่แล้ว

    when i try to debug my code i get this error "unable to find executable for "my work space location" and also when i click to run and debug, my vs code didn't show me the configuration option "gcc.exe - Build and debug..."
    any solution?

  • @mayanksingh1189
    @mayanksingh1189 ปีที่แล้ว

    Is somebody getting an error while 'run build task" at 9:48 section of the video cos I am getting task build with one error. Appreciate any help. Thanks in advance.

  • @kanhaiya3022
    @kanhaiya3022 3 ปีที่แล้ว +1

    Sir when I configuring task.json you told in that video it showing me && is not valid statement error

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      in Vs Code
      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe
      after that restart vs code and try

  • @Maverick-xd3di
    @Maverick-xd3di 3 ปีที่แล้ว +5

    Whenever I run any program it says
    gcc.exe: fatal error:no input files
    Compilation terminated.
    Please solve this

    • @alexagomez111
      @alexagomez111 3 ปีที่แล้ว +1

      I get the same error, where you able to solve it?

  • @mmmzzz2737
    @mmmzzz2737 ปีที่แล้ว

    I don't have a launch file like shown in the video. Actually after pressing Run and Debug button İt automatically debugged the file without configuration.
    Do I need a launch.json file that badly?

  • @sheetaldabke6963
    @sheetaldabke6963 3 ปีที่แล้ว

    Please help me I have do it 1st step everything clear bt the problem is when we can open terminal ..then configure build task..then next step is c c++ but my computer didn't show this then what we do please help me

  • @md.nahidulalamchowdhury9568
    @md.nahidulalamchowdhury9568 2 ปีที่แล้ว +1

    Thanks a lot, Sir!!! Keep going.

  • @vidiyal4156
    @vidiyal4156 2 ปีที่แล้ว

    Hi, Thanks for this useful video. when I tried to build an executable file(same program in try C language), I got an error"gcc.exe: fatal error: cannot execute 'cc1': CreateProcess: No such file or directory'' can you explain plz...

  • @malpaniparshusatish
    @malpaniparshusatish 2 ปีที่แล้ว

    getting error of preLunchTask"c/c++:gcc.exe build active file terminated with error" while clicking on run n debug

  • @michaelstuart2648
    @michaelstuart2648 ปีที่แล้ว

    Best tutorial! Thank you! Although the task configured to only build and run the file is not working

  • @prathamdevadiga5580
    @prathamdevadiga5580 2 ปีที่แล้ว

    At step mentioned in 16:09 I'm getting cc1.exe: fatal error: C++\{filename}.c: No such file or directory complilation terminated error..... What should I do here?

  • @usmanyousef1949
    @usmanyousef1949 3 ปีที่แล้ว

    RESOLVED - Error accessing correct directory & file
    Had the same error as others within the comments of not being able to access the Hello World terminal.
    cd stands for: Change Directory
    Used it as though I was clicking through my files. My error is that I was copying Anil and just typing Hello World.
    So, I was doing...C Programming -> Hello World
    Instead, my files were structured and should have been accessed as C Programming -> Programs -> Hello World
    My error was that I was using "cd Hello World" while my directory was still at the C Programming file. Make sure you are changing directories correctly- exactly as the directories are named.
    Hope this helped!

  • @ritikashishodia675
    @ritikashishodia675 2 ปีที่แล้ว

    Sir mer avs code extension nahi search kr rha h error in fetching bolra h Or bhaut late response kra h

  • @DS-im9oi
    @DS-im9oi 3 ปีที่แล้ว +1

    How to remove path directory in terminal!!

  • @isabelescarlette2021
    @isabelescarlette2021 3 ปีที่แล้ว +1

    Great tutorials, thank you very much!

    • @LearningLad
      @LearningLad  2 ปีที่แล้ว

      You're very welcome!

  • @picup30296
    @picup30296 3 ปีที่แล้ว +1

    I follow instruction of you tutorial to install the mysy, and it worked, but after I follow the instruction, setting up the default build task, gcc.exe, it pop up error saying like 'build terminated with code -1'. Did I do something wrong? Thank you.

    • @picup30296
      @picup30296 3 ปีที่แล้ว

      cmd still shows that gcc, g++, gdb version.

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      Can u provide more details

    • @picup30296
      @picup30296 3 ปีที่แล้ว

      @@LearningLad I will you provide the detail to you, but I am Chinese, so I will try my best to translate it, and uh I have important work now so I will send it maybe 6 hrs later.

    • @picup30296
      @picup30296 3 ปีที่แล้ว

      @@LearningLad But I can run the program by CMD and there is the .exe file, just wonder what do the code means

    • @picup30296
      @picup30296 3 ปีที่แล้ว

      @@LearningLad I knew what happened, it is because I use gcc for c++ program, and thus I change to g++, and everything is fine.

  • @sevginur
    @sevginur ปีที่แล้ว

    Debugging fonction runned to my code but launch.json not created. What do you think about it?

  • @matiasiudica3605
    @matiasiudica3605 3 ปีที่แล้ว

    nothing is working for me. Neither way i get the job done. First way says it doesnt recognize the name of the file but the path is fine. Second way the task doesnt show in the options to select it

  • @113sudharsanr6
    @113sudharsanr6 3 ปีที่แล้ว +1

    nice video but now 10.3 version came and it showing
    "THE token && is not the statement seperator in this version.
    + category info: parsererror: (:) [ ] parent contains error record expension
    + fully qualifiederrorId : invalid end of line"
    waiting for ur reply gentleman

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      In vs code
      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

    • @113sudharsanr6
      @113sudharsanr6 3 ปีที่แล้ว

      @@LearningLad can i contact u on TWITTER having some doubts

  • @frankbose544
    @frankbose544 2 ปีที่แล้ว

    i get an error idk i may messed something up but from what this says the && is not valid

  • @poddypust759
    @poddypust759 2 ปีที่แล้ว +2

    Youre a genius, thank you

  • @medha9997
    @medha9997 ปีที่แล้ว

    how to save the it 8:55?
    please answer this

  • @ektanagrale6911
    @ektanagrale6911 3 ปีที่แล้ว +3

    Im not getting errors im getting that && is not valid

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      In vs code
      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

    • @kallakarteek5945
      @kallakarteek5945 3 ปีที่แล้ว

      @@LearningLad thank you

  • @raghulprasaath3823
    @raghulprasaath3823 3 ปีที่แล้ว +1

    && command not recognised for me . pls help

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      go to view-> select command palate
      type "terminal:Select Default Profile"
      and set to command promt

    • @raghulprasaath3823
      @raghulprasaath3823 3 ปีที่แล้ว

      @@LearningLad Thanq bro

    • @raghulprasaath3823
      @raghulprasaath3823 3 ปีที่แล้ว

      @@LearningLad I am using code runner bro .

  • @diamondoinam621
    @diamondoinam621 2 ปีที่แล้ว

    Please tell me how to fix "The terminal process terminated with error code 1".

  • @sreekarg7583
    @sreekarg7583 3 ปีที่แล้ว

    Can u plz explain about CI continuous integration process for C and C++ programs, rite from src code merging to github and building and static code analysis wrt. quality and security stds, and building artifact out of it.

  • @amolmagar6468
    @amolmagar6468 3 ปีที่แล้ว +1

    How to delete that c programing folder from desktop, it shows you need administrator permission. I want to all from starting.

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      you can directly delete the file from desktop
      or
      open vs code as admin
      go to file
      choose close workspace
      restart vs code as admin
      you can start from beginning :)

  • @mansidara7427
    @mansidara7427 3 ปีที่แล้ว

    @learninglad I am not able to debug since the build task is failing due to some errors however have followed your steps clearly also have installed everything watching your videos please help me out

  • @RashmilDahanayake
    @RashmilDahanayake 3 ปีที่แล้ว +4

    When defining "Run this C Program" 13:30, you can do it by adding extra "args".
    "type": "shell",
    "label": "Run This C Program 2",
    "command": "gcc",
    "args": [
    "-g",
    "${file}", //${file} gives full path of the file
    "-o",
    "${fileDirname}\\${fileBasenameNoExtension}.exe", //output file name
    "&&", //to join building and running of the file
    "${fileDirname}\\${fileBasenameNoExtension}.exe"

    • @md.arrahmandip7638
      @md.arrahmandip7638 2 ปีที่แล้ว

      I spent 4 hrs finding the error swaping from "&&" to ";" , trying to figure out to run task but it was consistently showing the same error. Thnx to you that I could now run the task.

    • @letdoit1222
      @letdoit1222 11 หลายเดือนก่อน

      @@md.arrahmandip7638 hey man need your help 😭😭

  • @abhijeet3591
    @abhijeet3591 ปีที่แล้ว

    I'm Having a Debugging error I have searched the whole yt but didn't found a solution for my error somebody please help me out 😭😭😭

  • @fitivegaming
    @fitivegaming 3 ปีที่แล้ว +1

    Thanks for the video it worked! 😀

  • @amjadshuqair474
    @amjadshuqair474 2 ปีที่แล้ว +1

    Thank you very much for your tutorials! My only issue is when I write this code (pacman -Ss gbd ) Nothing happens

  • @vrajpatel1877
    @vrajpatel1877 3 ปีที่แล้ว +1

    Thank you very very much for this video

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      You are most welcome

  • @sarathjohnson9839
    @sarathjohnson9839 3 ปีที่แล้ว

    i have an error ,not getting o/p....pls do help

    • @sarathjohnson9839
      @sarathjohnson9839 3 ปีที่แล้ว

      + ~~
      The token '&&' is not a valid statement separator in this version.
      + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecor
      dException
      + FullyQualifiedErrorId : InvalidEndOfLine
      showing like this

  • @forthehorde2001
    @forthehorde2001 2 ปีที่แล้ว

    The token '&&' is not a valid statement separator in this version - error when up to 18:11 looks like : &&\"${fileDirname}\\${fileBasenameNoExtension}.exe\" any tips?

  • @hoangkhang5591
    @hoangkhang5591 ปีที่แล้ว +1

    Very helpfull!

  • @lauradancoso3041
    @lauradancoso3041 3 ปีที่แล้ว

    hi, im getting an error : No such file or directory

  • @raam6715
    @raam6715 2 ปีที่แล้ว

    How to set default terminal as cmd?

  • @sanketrao
    @sanketrao 2 ปีที่แล้ว

    works for OS X?

  • @khushinayak1413
    @khushinayak1413 2 ปีที่แล้ว

    This video is really helpful tysm ✨

    • @LearningLad
      @LearningLad  2 ปีที่แล้ว

      Glad it was helpful!

  • @bhanuprakashmpc8004
    @bhanuprakashmpc8004 3 ปีที่แล้ว

    Bro I can't do auto save it opening settings.json please help me

  • @Harshkumar-ox2lv
    @Harshkumar-ox2lv 2 ปีที่แล้ว

    "Cannot build and debug because the active file is not a a C or C++ source file." How to solve this problem 😭

    • @l_or_enzociotola8298
      @l_or_enzociotola8298 2 ปีที่แล้ว

      when in vscode click on cpp file, u r trying to compile .json file

  • @nery100
    @nery100 11 หลายเดือนก่อน +1

    I have the problem that when I'm debugging, I can't write in terminal any information that I request in my program, I mean that I only can debug a program that does not require any data given by the user, can somebody help me?

    • @F-m.a
      @F-m.a 10 หลายเดือนก่อน

      If you find a solution that doesn't require other extensions, please let me know! I'm having the same problem.

    • @malcolmbrt
      @malcolmbrt 2 หลายเดือนก่อน

      I have the same problem, did you find a solution?

  • @boopathysuntharanr1880
    @boopathysuntharanr1880 3 ปีที่แล้ว

    hi sir, could you show Steps for adding our own functions in C Library through visual studio code

  • @speedy9778
    @speedy9778 5 หลายเดือนก่อน +1

    GOAT

  • @nikolaradinovic6781
    @nikolaradinovic6781 2 ปีที่แล้ว +1

    At line:1 char:180
    + ... ikola\Desktop\C programming\programs\hello World\hello.exe &&c:\Users ...
    + ~~
    The token '&&' is not a valid statement separator in this version.
    + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : InvalidEndOfLine
    im getting this when i run the task

    • @LearningLad
      @LearningLad  2 ปีที่แล้ว

      in Vs Code
      Go to
      view -> command palette
      Search for select default shell
      Choose cmd.exe

  • @marshallsweatherhiking1820
    @marshallsweatherhiking1820 2 ปีที่แล้ว

    Where the hell does it look for the .exe when you're not compiling a single file. This is so annoying and confusing.

  • @Vantin33
    @Vantin33 2 ปีที่แล้ว

    Hello, could you help me please ? I have got the error : "&& invalid token" then i fix it by using your method that you provide in the section but know i got this:
    > Executing task in folder Programs: C:\Program Files\mingw64\bin\gcc.exe -g3 -Wall "c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.json" -o "c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.exe" &&"c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.exe" <
    'C:\Program' n’est pas reconnu en tant que commande interne
    ou externe, un programme exécutable ou un fichier de commandes.
    Arrêt du processus de terminal "C:\Windows\System32\cmd.exe /d /c C:\Program Files\mingw64\bin\gcc.exe -g3 -Wall "c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.json" -o "c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.exe" &&"c:\Users\valen\Desktop\Programmes C\Programs\.vscode\tasks.exe"". Code de sortie : 1.

    • @Vantin33
      @Vantin33 2 ปีที่แล้ว

      Here is my .json:
      {
      "version": "2.0.0",
      "tasks": [
      {
      "type": "cppbuild",
      "label": "C/C++: gcc.exe générer le fichier actif",
      "command": "C:\\Program Files\\mingw64\\bin\\gcc.exe",
      "args": [
      "-fdiagnostics-color=always",
      "-g3",
      "-Wall",
      "${file}",
      "-o",
      "${fileDirname}\\${fileBasenameNoExtension}.exe"
      ],
      "options": {
      "cwd": "${fileDirname}"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "group": {
      "kind": "build",
      "isDefault": true
      },
      "detail": "compilateur : \"C:\\Program Files\\mingw64\\bin\\gcc.exe\""
      },
      {
      "type": "shell",
      "label": "Run this C Program",
      "command": "C:\\Program Files\\mingw64\\bin\\gcc.exe -g3 -Wall \"${file}\" -o \"${fileDirname}\\${fileBasenameNoExtension}.exe\" &&\"${fileDirname}\\${fileBasenameNoExtension}.exe\"",
      "options": {
      "cwd": "${fileDirname}"
      },
      "problemMatcher": [
      "$gcc"
      ],
      "detail": "compilateur : \"C:\\Program Files\\mingw64\\bin\\gcc.exe\""
      },
      ]
      }

  • @geogaddi84
    @geogaddi84 3 ปีที่แล้ว +2

    I am getting a huge error string when I try to "run build task." I followed your previous tutorial for the compiler and debugger. I was able to do that just fine.

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +1

      Do u still have that error?
      If so then check your tasks.Json file
      And provide more details

    • @geogaddi84
      @geogaddi84 3 ปีที่แล้ว +1

      ​@@LearningLad It was late at night where I am at when I posted this. I am sure its late at night where you're at at this point. Thanks for reaching out to me for help. I sent you a DM in facebook with all of the screen shots that I think would be helpful. Any advice you could give me would be very great. Thanks!

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว +2

      i have replied to your query :)

    • @saiyanveins
      @saiyanveins 2 ปีที่แล้ว

      Hey Anil I am getting a weird error when I go to terminal and run task it tells me
      "At line:1 char 190
      +... Desktop/c programming/programs/Hello World/hello world.exe &&c:/Users ...
      ~~ the && shows a red squiggle under it and it won't compile :(

  • @adilch9793
    @adilch9793 3 ปีที่แล้ว

    9:56 they said terminal refused task and i didnt show up the hello world.exe

  • @sriramvedantam6537
    @sriramvedantam6537 3 ปีที่แล้ว

    i am still getting an error after 25:17 step

  • @DaveLight395
    @DaveLight395 ปีที่แล้ว

    * The terminal process failed to launch (exit code: -1).
    * Terminal will be reused by tasks, press any key to close it.

  • @rishuprasad8728
    @rishuprasad8728 3 ปีที่แล้ว

    Hello. I followed your last tutorial for mingw64 and I accidentally installed the wrong package. I wanted to restart completely to make sure I don't make any permanent errors. How do I reverse and uninstall everything on mingw64?

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      Use pacman -R the-package-name to remove whatever the package u have installed

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      Or uninstall msys2 and start again :)

    • @rishuprasad8728
      @rishuprasad8728 3 ปีที่แล้ว +1

      @@LearningLad so installing MSYS2 MSYS will uninstall everything?

    • @LearningLad
      @LearningLad  3 ปีที่แล้ว

      i think it will remove everything but to be sure, remove the unwanted packages u have using pacman -R package_name.

  • @cyber_dbs
    @cyber_dbs 2 ปีที่แล้ว +1

    nice tutorial

  • @jacobhatfield764
    @jacobhatfield764 2 ปีที่แล้ว

    Turn on subtitles if you have misophonia, it will save you the pain.

  • @Thewiseenigma
    @Thewiseenigma 3 ปีที่แล้ว

    7:04 it isn't appearing here

  • @AnilKumar-wz4zr
    @AnilKumar-wz4zr 3 ปีที่แล้ว +1

    Thank You

  • @justUry23
    @justUry23 ปีที่แล้ว

    it worked

  • @tom-huguesallard2899
    @tom-huguesallard2899 3 ปีที่แล้ว +1

    Thanks a lot LearningLad for this video :-)
    When I debug my program, nothing shows up in the terminal, do you know why please ?
    For example, 22:30 in your video, on my terminal it does not suggest me to enter my age, nothing happens...

    • @tom-huguesallard2899
      @tom-huguesallard2899 3 ปีที่แล้ว +1

      I succeeded to shows up outputs on a external terminal by changing the settings in launch.json -> "externalConsole": true,
      But i would like to know how to shows up outputs directly on VS like you do in your video.
      Thanks for your help

    • @orangeshoes
      @orangeshoes 3 ปีที่แล้ว

      I have the same issue.
      Can't see "Enter your age: " in the terminal.
      So, the debugger never really stops.

  • @sajawalali6163
    @sajawalali6163 ปีที่แล้ว +1

    In new version use ; instead of &&

  • @satyamtiwari3839
    @satyamtiwari3839 ปีที่แล้ว +1

    For new user you don't use && use -and

  • @adilch9793
    @adilch9793 3 ปีที่แล้ว +1

    i love india