-
Is there a way to tell that we will not end up in an infinite loop.(Except Dry run)
-
Did not understand - loading of hashMap will take O(N) time.
2 Doubts in video
hello @vishakha_narang
use hash map to keep track of visited values if any value visited again then that means loop is present otherwise not.
pls mention the timestamp where it is discussed
time - 3:55 . Does it mean creating takes O(N) time and searching O(1)
My first doubt is on the explanation at 6:10
what bhaiya was explaining is if u have to prepare map for n values then it will take O(N).
otherwise average searchtime is O(1).
yeah . check this->link
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.