import java.util.Scanner;

    public class Exercicio2 {

        public static void main(String[] args) {

            Scanner sc = new Scanner(System.in);

            int A = sc.nextInt();
            int B = sc.nextInt();

            if (A % B == 0 || B % A == 0) {
                System.out.println("Sao multiplos");
            } else  {
                System.out.println("Nao sao multiplos");
            }

            sc.close();
        }
    }
    

Embed on website

To embed this program on your website, copy the following code and paste it into your website's HTML: