(RankList for this Question)
You are given all distinct positive numbers between \(1, 2, 3, ⦠, n.\) Your task is to find the missing number
Constraints
\( 2 \leq n \leq 2 * 10^{4} \)
Input Format
First line contains the size of the array ānā
Second line contains n ā 1 numbers. Each number is distinct and in between 1 to n (inclusive)
Output Format
Example 1
Input:
7
7 6 1 2 4 3
Output:
5
Explanation:
5 is missing from that sequence
Log In to solve the Question