answersLogoWhite

0

How do you end a program in c?

Updated: 8/19/2019
User Avatar

Wiki User

13y ago

Best Answer

All C programs have a main() function, and when the end of that is reached, the program terminates, so to end a program, just type the ending curly bracket '}' to match the opening one of the main() function.

It is considered good practice to end a program with the statement 'return 0;' before the last curly bracket, to indicate that the program terminated normally.

User Avatar

Wiki User

13y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you end a program in c?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What is difference between stop and end in GWbasic?

The end command is used to end the program whereas the stop command is used to break the loop like ctrl+c. After running the program it will come as break in 20 or whatever


C program was introduced in the year?

c program was introduced in the year 1972 by Dennis RitchieNo, it was the C language, not the C program.


Features of c program?

the features of a C program


What is executive a c program?

I think it is 'execution of a C program'.


How to complete this C plus plus End Of File controlled while loop program?

Add the missing parts.


C program on left factoring in compiler design?

how to create a c program for left factoring.


Program for sin series in c language?

find the program in c-pgms.blogspot.com


Different parts of c language program?

what are the parts of C language program


Can you program games with c plus plus?

Yes, you can program games with C++.


Write a c program for creating a virus?

a c program for creat a virus


C program must have?

Not, there are many people, who live happily without C-program.


Write 8085 assembly language program for BCD up counter and display using 8279?

loop: mvi c,59 dcr c mov a,c daa movc,a jnz loop end