CSES Problemset/Introductory Problems
Missing Number
#1083Ask AI
Open a hint-first prompt in a new AI chat. Grok may ask you to confirm before sending.
Open Claude DesktopYou are given all numbers between except one. Your task is to find the missing number.
Input
The first input line contains an integer .
The second line contains numbers. Each number is distinct and between and (inclusive).
Output
Print the missing number.
Constraints
Sample Test Cases (1)
Example 1ID: sample-1
Input
5 2 3 1 5
Expected Output
4
Tools
1
2
3
4
5
6
7
8
9
10
11
12
Draft saved locally
|1 line, 0 charsTest Bench
Input (stdin)
5 2 3 1 5
Expected Output
4