Thursday, August 25, 2011
Multiplication Table Matrix using For Loop Statement
Turbo C program that display multiplication table by using for loop statement, furthermore it uses a loop within the loop statement.
Click Read More to get the Code:
#include<conio.h>
#include<stdio.h>
#define g gotoxy
#define p printf
main()
{
int s,d,a,z;
s=1;
d=1;
a=40;
z=1;
clrscr();
for(int i=1;i<=10;i++){
for(int j=1;j<=10;j++){
g(s,d);
p("%d",i*j);
s=s+3;
}
s=1;
d=d+1;
}
for(int e=1;e<=10;e++){
for(int r=1;r<=10;r++){
g(a,z);p("%d",e*r);
a=a+3;
}
a=40;
z=z+1;
}
getch();
return 0;
}
Labels:
C++,
Programming,
Turbo C,
Tutorial
Subscribe to:
Post Comments (Atom)
Watch Miss Universe 2011
Watch live streaming video from missuniverse at livestream.com
No comments:
Post a Comment