URI Problem 1044 Solution in Java

Problem Details Link

Solution:



import java.util.Scanner;

import java.util.Scanner;

/**
 * @Author : Muhammad Harun-Or-Roshid
 * @E-mail : md.parvez28@gmail.com
 * @Date   : Oct 10, 2016
 * @Time   : 11:01:05 PM
 */
public class Uri1044 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a,b;
        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");
        }
    }
}

Comments

Popular posts from this blog

URI Problem 1094 Solution in Java

URI Problem 1099 Solution in Java

URI Problem 1012 Solution in Java