0

Program to demonstrate exit statement

#include<iostream.h>

27th Jan 2019, 4:15 AM
Hemant Goswami
Hemant Goswami - avatar
3 odpowiedzi
+ 1
int main() { cout<<"loop"; for(i=0;i<10;i++) { cout<<i; if(i==6) exit(0); } cout<<"hello "; }
2nd Feb 2019, 11:20 AM
YUGRAJ
+ 1
Output ------------ loop0123456
2nd Feb 2019, 11:20 AM
YUGRAJ
+ 1
Here as you see hello is not printed so it mean after exit function program execution stops
2nd Feb 2019, 11:22 AM
YUGRAJ