Sir why you don't write j=i+1 in place of j=1 in for loop to find min element

sir after assigning the value of min index to say “i” then we have to compare the arr [min_index] to the other elements to the array so why you put the value of j=i but i think we have to put j=i+1

hello @anshulgurawalia

both will work.
u can follow any of them

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.