odd or even?
Submit solution
Points:
10
Time limit:
1.0s
Memory limit:
64M
Authors:
Problem type
Allowed languages
Java 19, Java 8
題目說明
輸入5個數字,判斷是奇數還是偶數,如果是奇數則輸出 true
,偶數則輸出 false
。
輸入
數字
輸出
boolean
記得 import.java.Scanner
sample input1
1 1 1 2 2
sample output1
true true true false false
sample input2
1 2 1 2 1
sample output2
true false true false true
Comments