forked from Akatakata/zerda-exam-cpp-basics
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path02.cpp
More file actions
27 lines (20 loc) · 625 Bytes
/
02.cpp
File metadata and controls
27 lines (20 loc) · 625 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//============================================================================
// Name : 02.cpp
// Author : Ak0s
// Description : Exam - task 2
//============================================================================
#include <iostream>
using namespace std;
void print_multi_table(int number);
int main() {
int number;
cout << "Which number's multiplication table do you wish to print?" << endl;
cin >> number;
print_multi_table(number);
return 0;
}
void print_multi_table(int number) {
for (int i = 1; i <= 10; i++) {
cout << i << " * " << number << " = " << i*number << endl;
}
}