백준 #21354번 Äpplen och päron

jhj·2024년 2월 13일

백준 JAVA

목록 보기
278/583
import java.util.Scanner;
public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		
		int a = sc.nextInt();
		int p = sc.nextInt();
		int totalA = 0, totalP = 0;
		
		totalA = a * 7;
		totalP = p * 13;
		
		if(totalA > totalP) {
			System.out.println("Axel");
		}else if(totalA < totalP) {
			System.out.println("Petra");
		}else {
			System.out.println("lika");
		}
		sc.close();
	}
}
profile
개발자를 꿈꾸는

0개의 댓글