#C13748. First Unique Integer
First Unique Integer
First Unique Integer
Your task is to find the first unique integer in an array. An integer is considered unique if it appears exactly once in the sequence.
Given an array \(A\) of \(n\) integers, you need to determine the first integer in the order of appearance that has a frequency of one. If there is no such element, output \(-1\).
inputFormat
The input is provided via standard input. The first line contains a single integer \(n\) representing the number of elements in the array. The second line contains \(n\) space-separated integers.
outputFormat
Output the first unique integer from the array. If no unique integer exists, output \(-1\).
## sample5
1 2 3 4 5
1
</p>