Solution -1

As the upper limit is given.. use hashing.. it'll give the solution in O(n)

Solution -2

Sum the numbers of the array and subtract if from the sum of the first n natural numbers.

i.e., let s be the sum of the array

then the missin number is

number = (n(n+1)/2) - s

others solutions are welcome i also want to know more solution for this problem