- 主页/
- 美图编程题
美图编程题
发布于 2017-04-16 20:21
1969 次浏览
0 赞
来自 资源分享
import java.util.Scanner; public class 一次的数字 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); String str = sc.nextLine(); String[] strs = str.split(","); int res = 0; for (int i = 0; i < strs.length; i++) { res ^= Integer.parseInt(strs[i]); } System.out.println(res); } } import java.util.Scanner; public class 游戏输赢{ public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); System.out.println(n%4!=0); } }
添加回复