+ 2
What is tha difference between "return 0" and "return 2(any other number)"?
Please describe..
3 Respostas
+ 3
Hi Priyo,
it's new type of statement, called a return statement. When an executable program finishes running, the main() function sends a value back to the operating system that indicates whether it was run successfully or not.
This particular return statement returns the value of 0 to the operating system, which means “everything went okay!”. Non-zero numbers are typically used to indicate that something went wrong, and the program had to abort.
+ 3
Thank you @Uttam..