Hi, Thanks for the explanation . Somehow , i think , a little change in indentation needed. Bcz, its not working for all the elements. so we have to change the index like i have shown below. def selectionsort(arr): n = len(arr) for i in range(n-1): mini = i for j in range(i+1,n): #
@RoshanSingh-kj4fy3 ай бұрын
I've attended multiple classes but ur simplicity is osam
@JupudiManikantaSwamy11 ай бұрын
I appreciate you taking the time to explain that. Thank you.
@unknownstudentkkn10 ай бұрын
sir iss video ko agar aap edit ya delete kar denge to bahut achha hoga kyunki isme error hai jisko aur bhi logo ne point out kiya hai aur jo pahli bar dekhenge wo samjhenge ki likha hua code hi sahi hai isliye please take a proper action..... swapping second loop complete hone ke baad ki jayegi...
@masterhipster83589 ай бұрын
correct
@Deeksha7star Жыл бұрын
Sir ye swapping j loop ke bhar m hogi
@Rohan-rr7jw Жыл бұрын
Yes bro you are right
@punitarora86642 ай бұрын
Great explanation sir
@yajushvyas291611 ай бұрын
Sir there is a mistake in pass 2, at 07:59 mini = 2 so after swapping in 09:07 when we will compare 42 we will compare it with 41 because mini = 2 and arr1[mini] = 41
@Hello_BhaiG3 ай бұрын
bhai code hi galat likha hai sir ne
@kareenatulyani2410 ай бұрын
Thankuuu sir❤
@aniketdev11578 ай бұрын
Thank you so much sir 🙏❤️
@wbinvestor771710 ай бұрын
There is a typing mistake in line no 8. The swapping must be done in the same indentation of the second for loop. Hope everyone evaluates correctly.
@talhajawad0208 ай бұрын
where the increment code of j exists in program?
@T_E_D_D_Y_0_0_76 ай бұрын
In python the by default increment value is 1 so you can omit that part if you want to increase by 1.
@gtsumit70677 ай бұрын
Hey, The line which you use for swapping will inside the first loop only as it's inside the second loop it could give wrong answer when there is a bigger array
@Hello_BhaiG3 ай бұрын
yup bro, the code is wrong. because of this video i waste my 2 hours, why i cant understand the logic and then after i realise the code is wrong so shameful teacher
@argaming9110 Жыл бұрын
Thanks sir
@niharikakadiyan8994 Жыл бұрын
Sir baaki sorting program b karwa do ... pgt k exam se phle
@Shaikh_Imran997710 ай бұрын
You consider n=5 but you run Nested For loop of j just 4 times why?
@shitikanthparida8270 Жыл бұрын
The 1st comment in Sir's video ❤️
@Deeksha7star Жыл бұрын
Sir heap sort b krado plz
@RajRaj-sp7xw5 ай бұрын
This code is not working for more than 5 elements.Could u help sir 🙏
@Hello_BhaiG3 ай бұрын
swapping wali 8th line inner loop se hata kar outer loop me laado, code me mistake h sir k
@AmishaJaiswal-qm4ek5 ай бұрын
it should be arr[j]
@unscinfinity33372 ай бұрын
Mini= I likha hain dekho
@md.mansoor64463 ай бұрын
This program is not giving proper output for some arrays