60 556
Assignments Done
97,9%
Successfully Done
In April 2018

Answer to Question #16430 in C++ for arif hussain

Question #16430
Q#1 Write a program to pass a number as argument to the function body. Print the table of that number in the function body
Expert's answer
#include <iostream>

#include<conio.h>

using namespace std;




void table(int,int);




void main(void)

{

int num,i;

cout << "Enter the number : " << endl;

cin >> num;

cout << "Upto how many multiples of the given number do you want? " << endl;

cin >> i;

table(num,i);

getch();

}




void table(int num,int i)

{

for(int j=1;j<=i;j++)

printf("
%5d * %5d = %5d",j,num,j*num);

}

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 first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions