1044 Multiples

SemiColon
By -
0
URI Online Judge | 1044

Multiples

Read two nteger values (A and B). After, the program should print the message "Sao Multiplos" (are multiples) or "Nao sao Multiplos" (aren’t multiples), corresponding to the read values.

Input

The input has two integer numbers.

Output

Print the relative message to the input as stated above.
Input SampleOutput Sample
6 24Sao Multiplos
6 25Nao sao Multiplos


Solution: 

#include<stdio.h>
int main()
{
    int a,b;

    scanf("%d %d",&a,&b);

    if (b%a==0 || a%b==0){
        printf("Sao Multiplos\n");
    }

        else {
            printf("Nao sao Multiplos\n");
        }
    return 0;

}


Tags:

Post a Comment

0Comments

Post a Comment (0)