top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How can I find a duplicate element in an array with a time complexity less than O(n^2) and a space complexity of O(1)?

0 votes
399 views
How can I find a duplicate element in an array with a time complexity less than O(n^2) and a space complexity of O(1)?
posted May 27, 2018 by anonymous

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+3 votes

In an "N" element integer sorted array, a particular elements is repeating "(N/2)+1" times. How much time it take to find the repeating element.

+2 votes

here is the sample code of problem :
a=100000000,b=200000;
multiplication=1;
while(a--){
multiplication=multiplication*b;
}
printf "multiplication= result"
reduce the time complexity by giving a suitable example which must have less complexity than this for large numbers.

...