Decode School

Decode School - The School for Problem Solvers
Welcome to My Blog.
Need Assignment / Project Guidance (or) Training in Python?

C Program to multiply two numbers

Get two integer numbers, multiply both the integers and dispaly the product.

Sample Input 1:

5 6 

Sample Output 1:

30

Sample Input 2: 

65 10

Sample Output 2:

650

Program or Solution

					    
							
//Program to Multiplication of two numbers
#include<stdio.h>
int main()
{
	int num1,num2,product;
	printf("Enter two numbers:");
	scanf("%d %d",&num1,&num2);
	product=num1*num2;
	printf("Product of two numbers: %d",product);
	return  0;
}
					    
					

Program Explanation

Get two integers a and b (using scanf statement) multiply a and b, then store the product in c (c=a*b) print the value of c (using printf statement)