though i did same code as sir told but the code isnt getting compiled
Code showing time limit exceeded error
hi @abhinavgoyal912 you have to break out of the loop if element is found. I have corrected your code here
Please mark the doubt as resolved 