Q15 Write a program to print the multiplication table of the number entered by the user. The table should get displayed in the following form:

Write a program to print the multiplication table of the number entered by the user. The table should get displayed in the following form:

Program: 108

Write a c program to print the multiplication table of the number entered by the user. The table should get displayed in the following form:

29 x 1 = 29
29 x 2 = 58

#include<stdio.h>
#include<conio.h>
int main()
{
    int i=1, num;

    printf("Enter number: ");
    scanf("%d", &num);

    while(i!=11)
    {
        printf("%d x %d = %d\n",num,i, num*i);
        i++;
    }
}

Output:

Enter number: 29
29 x 1 = 29
29 x 2 = 58
29 x 3 = 87
29 x 4 = 116
29 x 5 = 145
29 x 6 = 174
29 x 7 = 203
29 x 8 = 232
29 x 9 = 261
29 x 10 = 290

Lokesh Kumar: Being EASTER SCIENCE's founder, Lokesh Kumar wants to share his knowledge and ideas. His motive is "We assist you to choose the best", He believes in different thinking.
Related Post
Leave a Comment

This website uses cookies.