Kotlinlearncs.online LogoJava
Return to List

Solve: Common End

Imported By: Geoffrey Challen
/ Version: 2021.6.0

Given two non-null int[]s, return true if they have the same first element or they have the same last element. Both arrays will have length at least one.

boolean commonEnd(int[] first, int[] last) {
return false; // You may need to remove this starter code

Related Lessons

Stuck? You may find these lessons helpful: