saving . . . saved run and compile c and cpp program using notepad++ and gcc and g++ compiler has been deleted. run and compile c and cpp program using notepad++ and gcc and g++ compiler has been hidden .
run and compile c and cpp program using notepad++ and gcc and g++ compiler
Title
Question
We have windows OS 10 only in our college. I installed gcc and g++ compilers and notepad ++ in all PCs.  Can you kindly provide step by step procedure to write compile and run c and cpp programs using these editors and notepad++. It is a humble request. In instruction sheet ,It is not given properly.

C-and-Cpp First-C-Program 07-08 min 20-30 sec 27-02-20, 8:53 p.m. revathi.as

Answers:

Once you have written the code, open the Windows command prompt.
Using the cd command go to the folder where you have saved the file.
E.g.) c:\\\\Users\\\\(username)\\\\Desktop\\\\My-Code\\\\

To compile the c program, type on the command prompt: gcc talk.c -o myoutput

gcc is the compiler.

talk.c is the filename.

-o myoutput says that the executable should go to the file myoutput.


To execute the program, </span>type on the command prompt: ./myoutput
28-02-20, 5:25 p.m. pravin1389
Actually to execute the program the command should be the name of executable example myoutput.exe
30-11-22, 2:53 p.m. 123_priyansh

Login to add comment


'gcc' is not recognized as an internal or external command,
operable program or batch file.
What is the reason for this error.
25-01-21, 3:49 p.m. tatkalenterprises


Log-in to answer to this question.