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

  Рет қаралды 221,228

LearningLad

LearningLad

Күн бұрын

Пікірлер: 426
@naveed_snr
@naveed_snr 3 жыл бұрын
Tip: If you're using PowerShell as your default terminal (which is mostly the case for newer windows versions unless you have manually tweaked some settings) and are getting an error message after configuring Build and Run task, just set cmd as the default terminal or at 14:33 , replace the '&&' with a ';' as && is not recognized by powershell. BTW this is one of the best and most complete tutorials that you can find on VS Code setup.
@asmita7217
@asmita7217 2 жыл бұрын
thank you so much for this, as i was facing this problem. you are a life saver :)
@陳尚宏-n7x
@陳尚宏-n7x 2 жыл бұрын
I am so appreciate that you help me escape the nightmare!
@sourabhsinghrawat9066
@sourabhsinghrawat9066 2 жыл бұрын
Bro at which place?
@ternurasan
@ternurasan 2 жыл бұрын
You are a lifesaver! Thanks a lot!!!
@ternurasan
@ternurasan 2 жыл бұрын
@@sourabhsinghrawat9066 in the big line at 14:33 he uses && to connect "... .exe &&${fileDirname}..." instead of using && try using ; only, in case you're getting an error when running the code!
@atticusfoust6389
@atticusfoust6389 3 жыл бұрын
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!
@LearningLad
@LearningLad 3 жыл бұрын
Pleasure
@snehanshourya3850
@snehanshourya3850 3 жыл бұрын
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.
@bekzodhakimov4573
@bekzodhakimov4573 3 жыл бұрын
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
@LearningLad
@LearningLad 3 жыл бұрын
Glad I could help
@rohitpol
@rohitpol 3 жыл бұрын
Congratulations folks you guys have earned a rocket 🚀 science degree
@javabl3ck
@javabl3ck Жыл бұрын
Yo, this is some of the best programming tutorial I have seen ever. This guy knows his stuff. Thanks man.
@stephaniewanza8147
@stephaniewanza8147 Жыл бұрын
Hello, do you get this "replace the '&&' with a ';' as && is not recognized by powershell" I tried it on my Vs Code and it's giving an error. Pleaase help if you can
@javabl3ck
@javabl3ck Жыл бұрын
@@stephaniewanza8147 you are probably not using powershell as your default terminal. You should use the default code as it comes.
@mohammedimran6707
@mohammedimran6707 3 жыл бұрын
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 жыл бұрын
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 2 жыл бұрын
I tried but it still shows cc1.exe: fatal error(no such file or directory)
@thaboleroytheosmketsu8864
@thaboleroytheosmketsu8864 3 жыл бұрын
I am getting an error message which says && is not a valid statement separator in this version.
@alameen2784
@alameen2784 3 жыл бұрын
@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 3 жыл бұрын
@Aayushi what is it to update? can't follow through. tia
@usmanyousef1949
@usmanyousef1949 3 жыл бұрын
Prior to using VSC, I used CodeBlocks in my last programming class and compiling, running, and debugging seemed much simpler. I'm not going to lie, this has been pretty intimidating!
@chandrashekarr1977
@chandrashekarr1977 3 жыл бұрын
I am from turbo c c++ era... It was much simpler than these modern day craps... For the first time, am seeing a software from Microsoft which is not at all user friendly! Horrible
@mortenlund1418
@mortenlund1418 3 жыл бұрын
I have been folowing another tutorial on this subject (fortunately) and it is so much simpler. I cant think of a more complex way to get the same tasks done than this - ok if you choose to start digging for silicium to make your own chips maybe. I am a beginner and what I installed that did all what he is showing here ? For one an extension called coderunner. You only have to press a play botton.
@adityasrivastava6097
@adityasrivastava6097 2 жыл бұрын
1000%agree
@senuthmeerathnayake7899
@senuthmeerathnayake7899 2 жыл бұрын
so true...
@TechnoSan09
@TechnoSan09 2 жыл бұрын
ya but why im switching to VSC is in c::b i cant have more than one file in a project and cb doesn't compile the file which i'm working on and generates an error when there're more than one file with main() presented in a project
@thatguy8278
@thatguy8278 3 жыл бұрын
To execute Hello World in the Terminal I had to use ./"hello wrold"
@cameronfrancois1824
@cameronfrancois1824 3 жыл бұрын
Thank you
@harshvardhan1861
@harshvardhan1861 3 жыл бұрын
Thanks
@mansidara7427
@mansidara7427 3 жыл бұрын
thankyou brother your comment saved me
@ashrafulalam8402
@ashrafulalam8402 3 жыл бұрын
What's to be written to execute Compliment? Is it. /"Compliment"?
@Bunicher1
@Bunicher1 3 жыл бұрын
Thank you
@pravinbadhe5004
@pravinbadhe5004 3 жыл бұрын
Hi Go to view -> command palette Search for select default shell Choose cmd.exe Then also I have problem The token '&&' is not a valid statement separator in this version.
@LearningLad
@LearningLad 3 жыл бұрын
yes thank you for posting :)
@usmanyousef1949
@usmanyousef1949 3 жыл бұрын
This fixed the "&&" problem within the task for me. Thank you!
@TheC0ntrast
@TheC0ntrast 3 жыл бұрын
Awesome! Your post helps me to fix "&&" problem. Thank you!
@נתנאלטיקוצקי
@נתנאלטיקוצקי 2 жыл бұрын
That's help a lot, thank you!
@fatihcay3387
@fatihcay3387 2 жыл бұрын
The most video that i have ever seen about vsc debugging , thanks!!
@LearningLad
@LearningLad 2 жыл бұрын
Glad it was helpful!
@RaidenRaiden-r6g
@RaidenRaiden-r6g 3 ай бұрын
After 1 day of my life lost, I've finally found someone who solved my problem, many thanks bro
@LearningLad
@LearningLad 3 ай бұрын
Glad my video helped you
@AdmanAbid
@AdmanAbid Жыл бұрын
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 Жыл бұрын
yeah, me too, i just could type the age and not thing happen, but it seemed still happening
@malcolmbrt
@malcolmbrt 5 ай бұрын
I have the same problem, did you find a solution?
@anufyii
@anufyii 2 жыл бұрын
+ ~~ The token '&&' is not a valid statement separator in this version. + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : InvalidEndOfLine could you help please
@adilch9793
@adilch9793 2 жыл бұрын
replace && with ;
@letdoit1222
@letdoit1222 Жыл бұрын
@@adilch9793 na man it's not happening 😭
@rogerpark3221
@rogerpark3221 5 ай бұрын
Thanks for the info. was able to install the two programs successfully
@LearningLad
@LearningLad 5 ай бұрын
Most welcome :)
@lucasjoseserena2473
@lucasjoseserena2473 2 жыл бұрын
Thank you very much for the detailed information. You got a new suscriber :)
@LearningLad
@LearningLad 2 жыл бұрын
Awesome, thank you!
@rupalisharma7626
@rupalisharma7626 3 жыл бұрын
at 11:38 when i pressed enter ...instead of getting that enter the age message....i simply got = hello world.....what should i do now?
@LearningLad
@LearningLad 3 жыл бұрын
output depends on what program you are executing from the editor. check which program you have in the editor :)
@cameronfrancois1824
@cameronfrancois1824 3 жыл бұрын
I had to use ./"hello world"
@akshayshah8339
@akshayshah8339 3 жыл бұрын
In launch.json file when i write "externalConsole": true , it work fine with other console during debugging but as you did in the video when I put "externalConsole": false, terminal get stucked. It is not printing anything and also not allow to write anything for giving input. Could you help with this? In the video your terminal is working fine during debugging and i want the same.
@zetsu5648
@zetsu5648 4 ай бұрын
im also stuck at this please tell if you have found the solution
@yifeizhou1983
@yifeizhou1983 3 жыл бұрын
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?
@hrushikartejak3829
@hrushikartejak3829 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 жыл бұрын
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
@sandeeppremkumar8227
@sandeeppremkumar8227 3 жыл бұрын
Hey Man, Really Awesome Video, I seen lot of videos those all are really dumb, your video is clearly working in my PC Compiler Installation video also Really helpful to me, Thank You So much for this Video...
@LearningLad
@LearningLad 3 жыл бұрын
You're welcome!
@surxo-dk3xi
@surxo-dk3xi 4 жыл бұрын
Thanks for these tutorials! Really helpful.
@LearningLad
@LearningLad 4 жыл бұрын
pleasure :)
@chanchalsrajanagrawal7545
@chanchalsrajanagrawal7545 3 жыл бұрын
The best ever video for setup of vs code I have ever seen 😘🔥🔥🔥 Much appreciated😊😊
@LearningLad
@LearningLad 3 жыл бұрын
Thank you
@apeowo
@apeowo 2 жыл бұрын
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 жыл бұрын
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 жыл бұрын
@@apeowo check if u have installed mingw 32 or 64 bit
@rockymountainfacet5958
@rockymountainfacet5958 2 жыл бұрын
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
@malek6610
@malek6610 3 жыл бұрын
thanks a lot. I'm having a small issue. Whenever I name my folder/file, I get the message " the name ..... is not valid" can you help me, please?
@pierfrancescoemiliani3170
@pierfrancescoemiliani3170 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 жыл бұрын
Go to view -> command palette Search for select default shell Choose cmd.exe
@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?
@amolmagar6468
@amolmagar6468 3 жыл бұрын
Thanks for every single reply and giving so much time 🙏😍
@LearningLad
@LearningLad 3 жыл бұрын
My pleasure 😊
@alexagomez111
@alexagomez111 3 жыл бұрын
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 жыл бұрын
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 жыл бұрын
@@VorT6 hey bro can you pl tell the hole thing which you have typped in json
@m3ndez435
@m3ndez435 3 жыл бұрын
delete the whole launch.json file, and a new one will be generated when u do what he says
@040asysyaffakhoirunnisa6
@040asysyaffakhoirunnisa6 2 жыл бұрын
I have the sae issues. Could somebody help me please? I already installed the C/C++ extension
@wojciechpason4222
@wojciechpason4222 3 жыл бұрын
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 3 жыл бұрын
Go to view -> command palette Search for select default shell Choose cmd.exe
@kyrylosirenko2155
@kyrylosirenko2155 5 ай бұрын
@@LearningLad This helps, however, it launches cmd every time before actually working in the vs code terminal, which is annoying. Is there another fix?
@twotwo5579
@twotwo5579 3 жыл бұрын
Wow, u are amazing! You explain it very details. Thank you.
@LearningLad
@LearningLad 3 жыл бұрын
Pleasure
@prasadwakle2462
@prasadwakle2462 3 жыл бұрын
If the code runner extension is installed is it still necessary to set up build task?
@abhisheksinha2167
@abhisheksinha2167 3 жыл бұрын
hey i am getting a error . i.e Unable to start debugging . the value ofmiDebuggerPath is invalid .....plz help .. m stuck
@adityadawale7151
@adityadawale7151 2 жыл бұрын
I follow every step of your, still it shows fatal error (No such file or directory)after configuring the task. When I press Run this C program 18:55 it shows the error: cc1.exe: fatal error: Programming\Programs\HelloWorld\HelloWorld.c: No such file or directory Please help.
@Crimson_Playz
@Crimson_Playz 11 ай бұрын
did you find the solution? I am having the same issue
@lucas-jg2ce
@lucas-jg2ce 3 жыл бұрын
Man you always fix everything, thank you so much!
@LearningLad
@LearningLad 3 жыл бұрын
Happy to help!
@joaquinmucino3210
@joaquinmucino3210 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 4 жыл бұрын
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 жыл бұрын
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 жыл бұрын
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
@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??
@simo4win55
@simo4win55 2 жыл бұрын
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 4 ай бұрын
im having the same issue did u find the solution? thanks
@uchennagodfrey8343
@uchennagodfrey8343 Жыл бұрын
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 Жыл бұрын
yes follow the tutorials as they are in the playlist
@uchennagodfrey8343
@uchennagodfrey8343 Жыл бұрын
@@LearningLad Okay, thanks alot sir🙌 Learning alot tho just a beginner. Love the way you teach. Thanks again.
@LearningLad
@LearningLad Жыл бұрын
All the best :)
@pethupk9619
@pethupk9619 3 жыл бұрын
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
@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?
@martinmonte76
@martinmonte76 2 жыл бұрын
use a semicolon
@Missing2ndgear
@Missing2ndgear 3 жыл бұрын
Thank you for making this video, it helped me so much in setting up the c programming in visual studio code.
@LearningLad
@LearningLad 3 жыл бұрын
Pleasure
@md.nahidulalamchowdhury9568
@md.nahidulalamchowdhury9568 3 жыл бұрын
Thanks a lot, Sir!!! Keep going.
@LearningLad
@LearningLad 3 жыл бұрын
Most welcome!
@pratyush8983
@pratyush8983 2 жыл бұрын
Still problem continues. Not able to run debugger.
@florenti3336
@florenti3336 3 жыл бұрын
HELP: At line:1 char:154 + ... -o C:\Users\Florent Hyseni\Desktop\C++\Memory address.exe &&C:\Users ... + ~~ The token '&&' is not a valid statement separator in this version. + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : InvalidEndOfLine
@LearningLad
@LearningLad 3 жыл бұрын
post your tasks.json file content
@priyanshus3038
@priyanshus3038 3 жыл бұрын
Okay, the problem is that VS Code default terminal is Windows Powershell So you have to change your default terminal to Command Prompt Click on the Dropdown which shows Powershell besides the + sign for new terminal Click on Select Default Terminal You will see options to select from, select Command Prompt Then those commands will be executable
@daddandrea
@daddandrea 3 жыл бұрын
Hi, thank you for the tutorial, I have one big problem... When I click "Debug" it never actually starts debugging, can you help with that?
@daddandrea
@daddandrea 3 жыл бұрын
up
@amolmagar6468
@amolmagar6468 3 жыл бұрын
After run build terminal it shows output like Starting build... C:\msys64\mingw64\bin\gcc.exe -g3 -wall "C:\Users\amol magar\Desktop\c programing\programs\hello world.c" -o "C:\Users\amol magar\Desktop\c programing\programs\hello world.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). Terminal will be reused by tasks, press any key to close it.
@LearningLad
@LearningLad 3 жыл бұрын
You need to write capital w It should be -Wall
@RashmilDahanayake
@RashmilDahanayake 3 жыл бұрын
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 Жыл бұрын
@@md.arrahmandip7638 hey man need your help 😭😭
@octaviangabrielcotfasa6018
@octaviangabrielcotfasa6018 3 жыл бұрын
got an error saying " The token '&&' is not a valid statement separator in this version." can u help pls?
@LearningLad
@LearningLad 3 жыл бұрын
Please check other comments I have explained the setting where you can select cmd.exe instead of powershell
@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?
@satvik9677
@satvik9677 3 жыл бұрын
I was able to create an exe file for my helloworld program but then i made a new file and tried to create an exe file for that and it says .." collect2.exe: error: ld returned 1 exit status Build finished with error(s) " .. any help 😪😪🙏🙏
@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.
@pianissimo7121
@pianissimo7121 3 жыл бұрын
what if you have multiple .c files in src and the.h files in include folders, and a make file to build everything, I can now only run the code in terminal and cant debug it.
@fitiveg
@fitiveg 3 жыл бұрын
Thanks for the video it worked! 😀
@LearningLad
@LearningLad 3 жыл бұрын
Pleasure
@serollakrish3833
@serollakrish3833 3 жыл бұрын
sir am not able see C C++: gcc..exe in configure default task , i installed g++, gcc,gdb those are showing in cmd window with vesrion.... help me
@mmmzzz2737
@mmmzzz2737 2 жыл бұрын
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?
@malpaniparshusatish
@malpaniparshusatish 2 жыл бұрын
getting error of preLunchTask"c/c++:gcc.exe build active file terminated with error" while clicking on run n debug
@kanhaiya3022
@kanhaiya3022 3 жыл бұрын
Sir when I configuring task.json you told in that video it showing me && is not valid statement error
@LearningLad
@LearningLad 3 жыл бұрын
in Vs Code Go to view -> command palette Search for select default shell Choose cmd.exe after that restart vs code and try
@rowenasolar7275
@rowenasolar7275 3 жыл бұрын
Hi, I have one question about setting up build task and run program. Everytime I tried to type run exe file, it jumps out cmd and type this sentence in cmd "Enter your age: " I just type a number and it closed then it shows this sentence in the terminal in Visual Studio code "Enter your age: " and I type the same number it print out what it is in our program. Do you know why? If there is a problem?
@512akshitha5
@512akshitha5 2 жыл бұрын
When I run build task it displaying cmd is not recognised and build finished with errors
@suryansh70
@suryansh70 2 жыл бұрын
thank u sir nice explanation looking for this
@LearningLad
@LearningLad 2 жыл бұрын
Most welcome
@Hello_Hi_Bye_Bye
@Hello_Hi_Bye_Bye 2 жыл бұрын
vs code debbuging command prompt not showing up
@sevginur
@sevginur 2 жыл бұрын
Debugging fonction runned to my code but launch.json not created. What do you think about it?
@Maverick-xd3di
@Maverick-xd3di 3 жыл бұрын
Whenever I run any program it says gcc.exe: fatal error:no input files Compilation terminated. Please solve this
@alexagomez111
@alexagomez111 3 жыл бұрын
I get the same error, where you able to solve it?
@ramya8715
@ramya8715 3 жыл бұрын
When i hit the enter button after typing the executable file ..'The system cannot find the path specified' is displayed
@joharrizvi8988
@joharrizvi8988 3 жыл бұрын
did you manage to get any solution to this?
@pietropavesi9304
@pietropavesi9304 3 жыл бұрын
When at the last step I run the debugger, vscode gives me this error: Unable to start debugging. Unexpected GDB output from command "-gdb-set auto-solib-add on". No symbol table is loaded. Use the "file" command. Can anyone help me to solve this prob?
@cherpietro
@cherpietro 3 жыл бұрын
the program doesn't wright nothing on the terminal when there is a printf or get stuck when there is a scanf. Do you have any idea about how can I fix it? I'm codding in C. Thanks
@m3ndez435
@m3ndez435 3 жыл бұрын
remember to write scanf("", &variable);
@saradindu0207
@saradindu0207 2 жыл бұрын
When debugging a c program using VS code software using terminal >make the file ,it is showing configure launch.json .how can I solve this problem??
@dasarisrinith3037
@dasarisrinith3037 2 жыл бұрын
I have an issue..now when I use &&.. i am getting ..not a valid token seperator..how do I solve this? Please reply.
@poddypust759
@poddypust759 2 жыл бұрын
Youre a genius, thank you
@LearningLad
@LearningLad 2 жыл бұрын
most welcome :)
@ananyabanu6918
@ananyabanu6918 2 жыл бұрын
Sir after writing the name of the executive file and enter in the terminal I didn't get the line "Enter Your Age" What is the problem!!
@paschalerhurun6488
@paschalerhurun6488 2 жыл бұрын
This tutorial was truly helpful
@LearningLad
@LearningLad 2 жыл бұрын
Glad you think so!
@educatech8450
@educatech8450 2 жыл бұрын
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".
@sethandrewdacanay6988
@sethandrewdacanay6988 2 жыл бұрын
it doesn't work when I use shell bro, it only works with cmd terminal, how do I fix this?
@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
@achintsingh2575
@achintsingh2575 3 жыл бұрын
I followed your instructions by-the-book, but there is a problem that the program keeps saying "cannot open source file "stdio.h"C/C++(1696)".
@khushinayak1413
@khushinayak1413 2 жыл бұрын
This video is really helpful tysm ✨
@LearningLad
@LearningLad 2 жыл бұрын
Glad it was helpful!
@kpakfar
@kpakfar Жыл бұрын
How can I do the same process for multiple files C project?
@krishnav6561
@krishnav6561 3 жыл бұрын
I can't see the path in the default build tasks configuration. Can you help me??
@frankbose544
@frankbose544 3 жыл бұрын
i get an error idk i may messed something up but from what this says the && is not valid
@ganeshchandrameesala257
@ganeshchandrameesala257 3 жыл бұрын
When I hit enter after typing the executable file name in terminal it shows a huge error saying : ObjectNotFound But I'm in the exact folder and typed the exact name
@LearningLad
@LearningLad 3 жыл бұрын
Did you solved it? If not then pls provide more detail about the error
@ganeshchandrameesala257
@ganeshchandrameesala257 3 жыл бұрын
@@LearningLad oh I solved it. I changed all the single quotes in the code to double quotes that's it
@LearningLad
@LearningLad 3 жыл бұрын
K
@desp1c
@desp1c 2 жыл бұрын
Если вы не понимаете, что происходит в VSCode, или у вас просто какая-то ошибка, то лучше канала, пожалуй, не найти. Искал много русскоязычных объяснялок, только голову поломал. Тут всё кратко, и ясно.
@oken6325
@oken6325 Жыл бұрын
Is there an updated version of this tutorial? I'm using it in 2023 and nothing is going according to plan 😂
@naiwritmullick9918
@naiwritmullick9918 4 жыл бұрын
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 4 жыл бұрын
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).
@medha9997
@medha9997 Жыл бұрын
how to save the it 8:55? please answer this
@113sudharsanr6
@113sudharsanr6 3 жыл бұрын
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 жыл бұрын
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
@nadiam6791
@nadiam6791 3 жыл бұрын
i have a question.Can we write in terminal gcc -o hello world hello world.c to compile and then ./hello world instead of the prosess you made?
@isabelescarlette2021
@isabelescarlette2021 3 жыл бұрын
Great tutorials, thank you very much!
@LearningLad
@LearningLad 3 жыл бұрын
You're very welcome!
@amolmagar6468
@amolmagar6468 3 жыл бұрын
How to delete that c programing folder from desktop, it shows you need administrator permission. I want to all from starting.
@LearningLad
@LearningLad 3 жыл бұрын
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 :)
@vibhanshu986
@vibhanshu986 3 жыл бұрын
In the latest VSCode, 20:16 this option is not coming and an empty tasks.json file is created. How to get all configurations! If anyone can copy-paste that file in replies please
@m3ndez435
@m3ndez435 3 жыл бұрын
delete the launch.json file and when u do what he says, a new written one is generated
@sheetaldabke6963
@sheetaldabke6963 3 жыл бұрын
Please help out what can I do I have follow each n every step gcc then also I have errors pls help me
@ranjanamahto257
@ranjanamahto257 2 жыл бұрын
What should I do if it's printing hello world instead of running the file
@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...
@anishprem8112
@anishprem8112 3 жыл бұрын
Hello I'm a beginner in C program Can anyone tell me what learning lad has done in this video I didn't understand anything after the simple program of age..
@DevanshDixit
@DevanshDixit 4 жыл бұрын
At line:1 char:114 + ... iles C\helloworld.c -o D:\programme files C\helloworld.exe &&D:\progr ... + ~~ The token '&&' is not a valid statement separator in this version. + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : InvalidEndOfLine This is the error that I am getting , could you please help me resolve it ?
@DevanshDixit
@DevanshDixit 4 жыл бұрын
This got resolved by using a semicolon. The other problem that I faced was at 18:54 , this is still showing the same error even after using the /"
@LearningLad
@LearningLad 4 жыл бұрын
Can u post your task.json file content
@DevanshDixit
@DevanshDixit 4 жыл бұрын
@@LearningLad yeah { // See go.microsoft.com/fwlink/?LinkId=733558 // for the documentation about the tasks.json format "version": "2.0.0", "tasks": [ { "label": "echo", "type": "shell", "command": "echo h ello", "args": [ "-g", "hello.cpp" ], "group": "build", "problemMatcher": [] }, { "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" }, { "label": "echo", "type": "shell", "command": "echo h ello", "args": [ "-g", "hello.cpp" ], "group": "build", "problemMatcher": [] }, { "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 жыл бұрын
yes that semicolon is not required. you just need to use &&
@MarinaPopelov-df7pc
@MarinaPopelov-df7pc 2 жыл бұрын
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?
@diamondoinam621
@diamondoinam621 3 жыл бұрын
Please tell me how to fix "The terminal process terminated with error code 1".
@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
The Best Band 😅 #toshleh #viralshort
00:11
Toshleh
Рет қаралды 22 МЛН
Try this prank with your friends 😂 @karina-kola
00:18
Andrey Grechka
Рет қаралды 9 МЛН
How to Run C C++ Programs in Visual Studio Code
14:02
LearningLad
Рет қаралды 133
حل مشاكل فيجول استديو | visual studio code
18:47
اتعلم ببساطة
Рет қаралды 105 М.
Making My Own Programming Language and Coding a Game in It
10:19
AstroSam
Рет қаралды 1,3 МЛН
C++ in VS Code: Building your Code with CMake
9:37
Visual Studio Code
Рет қаралды 51 М.
Andrew Kelley   Practical Data Oriented Design (DoD)
46:40
ChimiChanga
Рет қаралды 153 М.
Compile and run C code using Visual Studio Code (2021)
15:51
CodeVault
Рет қаралды 90 М.