I don't follow Portugese very well, but I'll do my best.
1 - For n<=20 elements, use a brute-force n2 method: check that element 1 != any element in 3..n; then check that element 2 != any element in 4..n; etc. That'll take two loops, one inside the other.
2 - You'll need a second array. Copy the numbers from the first array to the second array, but only copy a number if it is not already in the second array. (You can check because if it is, it'll be the last number copied.)
(Technically, you don't need a second array. You only need to remember what the last number you copied/printed was.)
> You only need to remember what the last number you copied/printed was
For (2) it does not says that the input is sorted. You can solve it with a simple variation of the solution for (1) where you would not check all the range, but only the already visited values.
Edit: or when (1) reports a repeated element, you simply continue the loop