Question: Given an array nums containing n unsorted distinct numbers in the range 0 , n , return the only number in the range that is

Given an array nums containing n unsorted distinct numbers in the range 0,n, return the only number in the range that is missing from the array.
Example input/output:
0,1,2 return 3,
1,0,3,4 returns 2
Criteria:
\table[[Test #,Input,Output],[1,0,1,2,3],[2,1,0,3,4,2],[3,7,0,1,2,3,4,5,7,8,6],[4,\table[[,],[10,11
 Given an array nums containing n unsorted distinct numbers in the

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!