- 1

what is the use of return 0?

10th Aug 2016, 12:52 PM
KRISHNA GOGI
KRISHNA GOGI - avatar
4 Answers
+ 1
to tell compiler that program is executed successfully
10th Aug 2016, 2:37 PM
Soutik
Soutik - avatar
+ 1
it tells the compiler that program is successfully executed if we write return 1 in place of return 0 then compiler will think that there will be abnormal execution and it will again check the code if there is some mistake if not OS cannot understand
11th Aug 2016, 3:40 PM
PRANJAL AGNIHOTRI
PRANJAL AGNIHOTRI - avatar
+ 1
no need of giving return 0 if u use int main() as main()
12th Aug 2016, 4:14 AM
Durgaprasad
0
it tell the compiler that the program is executed without any error &successfully
11th Aug 2016, 1:42 PM
ANKIT BHALWAL
ANKIT BHALWAL - avatar