본문 바로가기

IT개발자/백준_Algorithm

백준 10430번 JAVA(자바) 문제 풀이

728x90
반응형
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		
		int A = scan.nextInt();
		int B = scan.nextInt();
        int C = scan.nextInt();

		System.out.println((A+B)%C);
        System.out.println(((A%C) + (B%C))%C);
		System.out.println((A*B)%C);
        System.out.println(((A%C) * (B%C))%C);
        
	}

}
728x90
반응형