Imagine the user enters a two lists of integers, where the second is always less than or equal to three elements long.
Write code that will return true or false whether or not the shorter list is a
sub-list of the first list. For example, if the user enters the list [7, 1, 2, 3, 2, 4, 1, 3] and
[3, 2, 4] your code would return true , but if the second list was [3, 2, 3]
your code would return false .Please do not use any Java code or libraries that we have not covered in class; this defeats the purpose of the assessment. |