#910. only14
only14
Background
Description
Given an array of ints, return true if every element is a 1 or a 4.
Format
Input
Output
Samples
[1 4 1 4]
true
[1 4 2 4]
false
[1 1]
true
Limitation
1s, 1024KiB for each test case.
Given an array of ints, return true if every element is a 1 or a 4.
[1 4 1 4]
true
[1 4 2 4]
false
[1 1]
true
1s, 1024KiB for each test case.
By signing up a 算道OJ universal account, you can submit code and join discussions in all online judging services provided by us.