0

C++ program please help me how to solve this problem

Task 3 Write and run a program that reads two integers and then uses the conditional expression operator to print multiple or not, according to whether one of the integers is a multiple of the other. Sample Input: 12 6 First is multiple of second 12 = 6 * 2 Sample Input: 18 8 Neither are multiple 18 = 8 * 2 + 2 Sample Input: 12 36 Second is multiple of first 36 = 12 * 3

7th May 2018, 4:26 PM
Bilal
2 Respostas
0
if (a%b==0) a is multiple of b if (b%a==0) b is multiple of a
7th May 2018, 5:03 PM
michal
7th May 2018, 5:14 PM
Sreejith P
Sreejith P - avatar