題目: 麥哲倫的陰謀
import java.util.Scanner;
public class GuessHat{
public static Scanner sc = new Scanner(System.in);
public static long n,m;
public static void main(String args[]){
while(sc.hasNext()){
n = sc.nextLong();
m = sc.nextLong();
System.out.println((m != n) ? m+1 : m);
}
}
}
沒有留言:
張貼留言