Lecture 122
// Loop do while
//Nested for loop
#include <iostream>
#include <conio.h>
using namespace std;
main ()
{
int row,col;
row=1;
do
{
col=1;
do{
cout<<col*row<<"\xb3";
col++;
}while(col<13);//inner loop
cout<<endl;
row++;
}while(row<13);//outer loop
getch();
return 0;
}
Code view in dev compiler:
Compile the program Ctrl+F9
Run program Ctrl+F10