Canadian Computing Competition: 2003 Stage 2, Day 2, Problem 2
Within a sequence
In other words, find the longest contiguous subsequence in which no
integer is repeated. If there are several such subsequences, find the
one that occurs first in
Input Specification
The input will consist of the elements of
Each element of
Output Specification
The output should contain the correct subsequence of
Sample Input
Copy
1
9
5
3
1
2
8
3
9
0
Sample Output
Copy
9
5
3
1
2
8
Comments
0 < |S| < 1131069.