import java.util.Scanner;

class TestVar {
    public static void main(String [] args) {
        int input = 0;
        System.out.print("정수 입력 : ");
        Scanner in = new Scanner(System.in);
        input = in.nextInt();
        
        if(input % 2 == 0) {
                System.out.println("2의 배수");
        }
        if(input % 3 == 0) {
                System.out.println("3의 배수");
        }
        
        
    }
}
Posted by ▶파이팅◀

블로그 이미지
Let's start carefully from the beginning
▶파이팅◀

태그목록

공지사항

Yesterday
Today
Total

달력

 « |  » 2025.7
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31

최근에 올라온 글

최근에 달린 댓글

글 보관함