write a program for n number of table using for loop in c
#include
int main()
{
int i,n,f;
printf("enter table end:");
scanf("%d",&f);
printf("enter table number:");
scanf("%d",&n);
for(i=1;i<=f;i++)
{
printf("%dx%d=%d\n",n,i,n*i);
}
}
example output:
enter table end:10
enter table number:12
12x1=12
12x2=24
12x3=36
12x4=48
12x5=60
12x6=72
12x7=84
12x8=96
12x9=108
12x10=120
Comments
Post a Comment