Inserting/Adding Elements Before The Given Node in The Linked List | Python Program

  Рет қаралды 53,880

Amulya's Academy

Amulya's Academy

Күн бұрын

Пікірлер: 63
@gajanantayde
@gajanantayde 3 жыл бұрын
This is a very high quality playlist to learn Data structures in python!!!!!!!!!! superb👏👏👏
@bakhitmahamat7359
@bakhitmahamat7359 4 жыл бұрын
I don’t know how much to thank you Ma’am. I was struggling before to understand DSA but r now with your well detailed explanation, I’m catching up. You’re the best! 😂😂 You’ve got also a fantastic voice😂😂.
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
Glad to hear that :)
@jaheerkalanthar816
@jaheerkalanthar816 4 жыл бұрын
Your voice so cute Sister,It is like some Melody, Im a beginner of Python i trying to understand Data Structure,Most of other Tutorials They teach for advanced students,You only teach the Data Structure for Begginner we Love You Teaching Sister Keep Going
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
Thank you so much :)
@saradaprasad9594
@saradaprasad9594 3 жыл бұрын
I like the way you teach even I'm able to understand these concepts, initially i thought it would be difficult for me but now i'm able to understand DS thank you
@hustlersadda1
@hustlersadda1 Жыл бұрын
Thank you🥺❤ I can't find better explanation then this. Keep educating us.
@prateektiwari4116
@prateektiwari4116 3 жыл бұрын
U r osmm🙏🙏🙏🙏💘 really i tried to understand from many channels but stills didn't understand anything but u made it simple for me..... 💗💗💗
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Thank you so much 😀
@rahulsolanki5535
@rahulsolanki5535 3 жыл бұрын
Wonder woman of DSA love your voice and explanation.
@anuragchandra7850
@anuragchandra7850 3 жыл бұрын
It is impossible to explain better than this❤️❤️❤️
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Thank you 😊❤️
@keerthanaselvanathan4510
@keerthanaselvanathan4510 3 жыл бұрын
you are really great mam and your voice too...... The way you are explaining is great, clear..!!!!! I feel very happy after watching your video. Thank you so much mam. Do continue!!.Its my hearty request.
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Thank you 😊❤️
@dewangpatil4990
@dewangpatil4990 3 жыл бұрын
Thank you sooooo much, ma'am. If you wasn't there my ds was not going to get started
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Pleasure 😊❤️
@snehaa5682
@snehaa5682 4 жыл бұрын
Mam.. 🤩 really u explained well, u teach from basic, keep it up mam
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
Thanks a lot 😊
@cineclassicshub
@cineclassicshub 2 жыл бұрын
while True: print("❤❤❤❤❤East or West Amulya ma'am is the best!❤❤❤❤❤")
@snex-techprogrammer5110
@snex-techprogrammer5110 2 жыл бұрын
Top notch level of explanation....Thanks for this great content for free
@vishaljagale6342
@vishaljagale6342 3 жыл бұрын
Great Conceptual Learning in an easy Manner. Thankyou so much Mam.
@vamsinadh100
@vamsinadh100 3 жыл бұрын
def insert_before(self,data,x): n = self.head while n.next.data!=x: n = n.next if n.next==None: print(x,"is not in the list") return self.insert_after(data,n.data) This code works for inserting data before an element.simple!
@TinytotsWorld16
@TinytotsWorld16 2 жыл бұрын
Y return is given ?
@keshav9759
@keshav9759 2 жыл бұрын
Thankyou mam You cleared me the concepts which no'one could.
@TarunKumar-hv6jk
@TarunKumar-hv6jk Жыл бұрын
Where can i practice DS problems from basic
@abhishekchakraborty15
@abhishekchakraborty15 2 жыл бұрын
You are the best !
@shuaibsaqib5085
@shuaibsaqib5085 2 жыл бұрын
very awesome explanation......Thank You
@svsc729
@svsc729 Жыл бұрын
Excellent tutorial mam. Small suggestion: Would it be possible to maintain a Git repo for all your code and paste the link to it here.
@revanth_richards
@revanth_richards 5 ай бұрын
can you cover the advanced topics..??
@pini5076
@pini5076 Жыл бұрын
Thank you so much!
@ghemanthkumar8183
@ghemanthkumar8183 4 жыл бұрын
Thank you mam 😊 Ur teaching is best than our lectures, as I'm a beginner, I'm trying to improve my logics but I don't know what to do ? Can u give any suggestions from ur side mam?
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
Thank you :) Practice programs try to write your own version of program for a problem :)
@sm-df6ft
@sm-df6ft 3 жыл бұрын
Explaination is too good I really understand the concept but ,i have a question do we need to create node class and linkedlist class for head on every time for evy operation of linked list like reverse or find middle element
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
No while adding new nodes you need to create new node for that you need to use Node class :)
@sm-df6ft
@sm-df6ft 3 жыл бұрын
@@AmulsAcademy thanks maam
@Kavya-d8l
@Kavya-d8l 5 ай бұрын
Can you clarify me the difference between 'while n is None' and 'while n.ref is None' . How these two conditions works in different way!
@prachi7414
@prachi7414 3 жыл бұрын
I have a doubt that why u used return in second if block in add_before method???
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
If the condition of if block is true , after executing its body I want to stop the execution of the function 😊
@prachi7414
@prachi7414 3 жыл бұрын
@@AmulsAcademy thankyou!!!! Much
@sktanweerrahaman9896
@sktanweerrahaman9896 3 жыл бұрын
Can't we call directly the add_begin fn inside the add_before instead of copying the code from it?
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Yes you can 😊
@sktanweerrahaman9896
@sktanweerrahaman9896 3 жыл бұрын
Ok mam..thanks..your teaching is awesome
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
❤️
@bablumishra9789
@bablumishra9789 4 жыл бұрын
Hi amulya, Thanks for the wonderful session on adding element before a NODE. But as I am executing the code provided by you its showing an Error as " Linked list object has no attribute head".
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
In the Linked List class you need initialise head ... Watch the video completely :)
@chilakaprasanthkumar1770
@chilakaprasanthkumar1770 Жыл бұрын
@@AmulsAcademy 🤣😂
@Unknownthewiu
@Unknownthewiu Жыл бұрын
Anyone explain? Why I can't use while n is not None , but n.ref? Can't I just use while n is not None and if n is None?
@DACS_NARESHKUMARP
@DACS_NARESHKUMARP 3 жыл бұрын
At the condition first node ==x Why didn't you used n instead u used self. Head Iam not getting answer for using n
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
I am referring first node and we can access first node data using self.head.data also. if you want you can use n also. :)
@makeyoulaugh5616
@makeyoulaugh5616 3 жыл бұрын
Please recommend me a book for dsa using python
@AliKhan-rr6kz
@AliKhan-rr6kz 3 жыл бұрын
while n.ref is not None: if n.ref.data ==x: new_node.ref = n.ref n.ref=new_node break n=n.ref why we need to add break in the loop here,if i remove break while loop is running continuously .i dont get it, loop should end after the last node right? where last node ref is none then loops terminates.can anyone help plz.
@chaitanyakrishna9398
@chaitanyakrishna9398 3 жыл бұрын
At time stamp 6:03 Cant, we call the add_begin function in add_after function when x is the head data instead of copying the code again. I tried this but showed an error so please explain how to call a method in another method of the same class in python.
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
Try self.method name :)
@Biswajit_Pradhan
@Biswajit_Pradhan 2 жыл бұрын
mam don't know why but code is showing run time error def add_before(self,data,x): if self.head is None: print(" Linked List is empty") return if self.head.data==x: new_node=Node(data) new_node.ref=self.head self.head=new_node print(" Node inserted successfully ") return n=self.head while n.ref is not None: if n.ref.data==x: break n=n.ref if n.ref is None: print("Node is not present in the Linked List") else: new_node=Node(data) new_node.ref=n.ref n.ref=new_node print(" Node inserted successfully ") return this is my code..and while I am trying to insert a node at the starting position it is showing that "Node is not present in the Linked List" . Please help me on this
@iNeFFaBLeSaPiEN
@iNeFFaBLeSaPiEN Жыл бұрын
600th like
@amarnathr2348
@amarnathr2348 3 жыл бұрын
Please provide notes mam WE CAN REFER
@AmulsAcademy
@AmulsAcademy 3 жыл бұрын
I will try :)
@selvanm2872
@selvanm2872 4 жыл бұрын
👍
@AmulsAcademy
@AmulsAcademy 4 жыл бұрын
Thank you :)
@saikrishnacherala2519
@saikrishnacherala2519 2 жыл бұрын
if any one has wrote this data structrures notes or anybody has all the notes written.. if Yes please send me
@tharuntharak2548
@tharuntharak2548 2 жыл бұрын
It's not inserting the element before the given node(x). It is inserting only if the x value equals to the first node. Please help me Ma'am. I have written the same code as you.🥲
@hustlersadda1
@hustlersadda1 Жыл бұрын
You pasted the another else: Just watch the video and write as ma'am has written. I'm telling you because this happens with me also. Don't worry just write as ma'am did 😊
Inserting/Adding Elements To The Empty Linked List | Python Program
5:07
Ice Cream or Surprise Trip Around the World?
00:31
Hungry FAM
Рет қаралды 10 МЛН
Which team will win? Team Joy or Team Gumball?! 🤔
00:29
BigSchool
Рет қаралды 15 МЛН
5 Useful F-String Tricks In Python
10:02
Indently
Рет қаралды 325 М.
LINKED LIST (CREATION AND DISPLAY) - DATA STRUCTURES
42:19
Sundeep Saradhi Kanthety
Рет қаралды 369 М.
Data Structures in Python: Singly Linked Lists -- Deletion
16:31
LucidProgramming
Рет қаралды 37 М.
Linked Lists for Technical Interviews - Full Course
1:27:24
freeCodeCamp.org
Рет қаралды 365 М.
Solve any Star Pattern program in Python
18:44
Simply Coding
Рет қаралды 1 МЛН
Inserting/Adding Elements At The End Of The Linked List | Python Program
13:16
Ice Cream or Surprise Trip Around the World?
00:31
Hungry FAM
Рет қаралды 10 МЛН