Advertisement

WRITE A PROGRAM USER CREATE A TABLE IN TABLE FORMAT

#include<stdio.h>
#include<conio.h>
void main()
{
clrscr();
int a,b,c;
printf("ENTER NUMBER WHICH YOU WANT TO VIEW A TABLE\n\n");
scanf("%d" ,&a);
for(b=1;b<=10;b++)
//b is locate range in or looping 10 is looping time
{
c=a*b;
printf("%d\t*\t%d\t=\t%d\n" ,a,b,c);
}
getch();
}


OUTPUT
6 * 1 = 6  
TABLE SHOW LIKE THAT AND ITS RUN 1 TO 10

Post a Comment

0 Comments