Answer to Question #243867 in C++ for xtian

Question #243867

 LOOP: (TURBOc++)



 

Prg15: Write a program that displays a multiplication table for a given number.

Sample output:      Enter a number: 3

                              Multiplication table for 3:

 3 x 0 = 0

3 x 1 = 3

3  x 9 =27



PLEASE USE:

#include<stdio.h>

#include<conio.h>


scanf

printf

 


example:

#include<stdio.h>

#include<conio.h>

main()

{

int n=1, x=20;

clrscr();

printf("While Loop Example");


while (n<=5)

{

gotoxy(x, 3);printf(" %d", n);

n++;x=x+5;

}

getch();

}


1
Expert's answer
2021-09-30T06:47:22-0400
#include<stdio.h>


#include<conio.h>


main()


{








int n;
printf("Enter a number\n");
scanf("%d", &n);
int i  = 0;




while (i<=12)


{


printf("%d * %d = %d\n", n, i, (n*i));


i++;


}
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS