Skip to content

Instantly share code, notes, and snippets.

@folivetti
Created February 17, 2017 16:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save folivetti/1eb948358d9ef5d8e1f5b5a89d5be82a to your computer and use it in GitHub Desktop.
Save folivetti/1eb948358d9ef5d8e1f5b5a89d5be82a to your computer and use it in GitHub Desktop.
import java.io.IOException;
import java.util.Scanner;
public class Main {
public static void main(String[] args) throws IOException {
int A, B;
Scanner sc = new Scanner(System.in);
A = sc.nextInt();
B = sc.nextInt();
if ( (B%A) == 0 || (A%B) == 0) {
System.out.println("Sao Multiplos");
} else {
System.out.println("Nao sao Multiplos");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment