#9. commonEnd
commonEnd
Background
Description
Given 2 arrays of ints, a and b, return true if they have the same first element or they have the same last element. Both arrays will be length 1 or more.
Format
Input
Output
Samples
[1 2 3] [7 3]
true
[1 2 3] [7 3 2]
false
[1 2 3] [1 3]
true
Limitation
1s, 1024KiB for each test case.