8. Determine the output of each of the following programs when it is executed. (a) #include using namespace std; int main() { } (b) bool flag = true; int i = 0; while (flag) cout #include...




8. Determine the output of each of the following programs when it is executed.


(a)


#include using namespace std; int main()


{














}


(b)




bool flag = true; int i = 0;


while (flag)


cout <><><“\n”;>




#include using namespace std; int main()


{














}


(c)




bool flag = true; int i = 0;


while (flag)


cout <><><“\n”;>




#include using namespace std; int main()


{












}


(d)




int i = 0;


while ( !!!(true) )


cout <><><“\n”;>




#include using namespace std; int main()


{


int i = 0; while ()


cout <><><“\n”;>


}










(e)


#include using namespace std; int main()


{


int j = 0; while ( j ) {


cout <><>








}


(f)




}


return 0;




#include using namespace std; int main()


{


int j = 1; while ( j ) {


cout <><>








}


(g)




}


return 0;




#include using namespace std; int main()


{












}


(h)




int j = -6; while ( j )


cout <><>




#include using namespace std; int main()


{


int i = 0,n = 10,counter = 0; while ( i


cout \n”; i += 4;


cout \n”; i -= 2;


counter++;


cout <><>


}


cout <“no><><>


}


(i)


#include using namespace std;




int main()


{


int i = 0,n = 10;


int j = 0,inner = 0,outer = 0; while ( i


cout <“komputer>


while ( j <>


cout <“hello>


inner++;


}


i += 4;


outer++;


}


cout <“no><“loop><>


cout <“no>“; cout <“loop><><> 0;


}
















May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here