Computer Science, asked by BastavBoruah, 9 months ago

why return 0 is used in c program ​

Answers

Answered by riya552
1

Explanation:

  • In C and C++ programs the main function is of type int and therefore it should return an integer value. The return value of the main function is considered the "Exit Status" of the application. On most operating systems returning 0 is a success status like saying "The program worked fine
Answered by Anonymous
6

Answer:

Almost in each program we use a code i.e.

return \:  \:  \: 0; \:

when we end the main function.

Explanation:

Because,main function requires a particular signature.

the return is the exit code of your program.

by who's you can read and use it.

the 0 is exit code which means "ok the program execution was s successful"

Hope it helps you.

❤️AR+NAV❤️

Similar questions