Be sure that the length of the longest sequence is calculated correctly when it is located at the end of the list of entered numbers.