See complete series on linked list here:
In this lesson, we will see implementation of basic insertion and traversal of a linked list.
Lesson on Dynamic memory allocation (malloc, new etc) –
Series on pointers in C/C++:
Drop your questions/queries in comments section.
mycodeschool on facebook :
Nguồn:https://wijstaanvooronzegrondrechten.org/
java mai bhi sikhado
i have seen many coding videos on YouTube.
but this channel has always provided me with the best explanations so far.
thanks a lot for all your amazing videos.
Why do we need pointer for creating nodes?why cant with normal variables?
Like Node temp; instead of Node* temp
abe nahi chalra ye
s
32dpehle khud try iya alladddkak
wow!!!. i am just speechless,amazing content you have,you're superb dude!!!.
Thanks a lot for this amazing work i was about to break down over linked lists and then you showed up man you are a life saver … i have aquestion though at the end when i want to print my elements all i get is a 4 do i tried writing printf in every loop but i still get the same result can you kindly calrify this particular problem how do i print all elements after i've traversed through the list
thanks alot in advance and keep up the amazing work
Thanks alot ❤
I still remember when I studied data structure in C. Sadly it is now knowledge of the past. No one in the world looks for C or data structure related skills anymore.
its actually very easy but only when its taught by a good teacher! Thank you so much, was very easy to unterstand!
n nothing taught like this in the school
I just want that the god may return real god back to us
2019 im here ….
So when you want to insert a new element into the linked list, you want temp->link to point to the address of the next cell, right? It won't be NULL anymore, but how do you write that you want to point to the next cell?
https://www.hackinfy.com/ . Please visit my blog.
Has anyone ever really tried it using C++??? cus the thing is this linked-list is not really linked!!!!! I agree that you explain the linked list in a nice way but the implementation cannot work
Anyone in 2019?
Who searching anthony
If you wanted to make a new node, and your node* temp was still pointing to the last node, couldn't you just do:
*(temp).next = new Node();
To add a node to the end?
I think a void ptr can actually be used for any kind of ptr!
Thank you. I realized my mistake and learned something new, god bless!
Can linked lists be implemented in java? If not, then in what other languages can it be implemented?
hii sir…but u didn't declare temp…..how the program will execute
I can't support you because I am a student but I always keep my adblock off in your videos ..
Thankyou so much for your hard work .. Really learnt a lot from your videos ..I wish I could have teachers like you in my college ..
Last 30 seconds were confusing as all hell. what is temp1->link = temp? Why not just temp1 = temp?
Sir in last when u use temp1-›link=temp than why don't you use temp1 =temp directly
12:16
Shouldn't we delete or free the temp variable to avoid memory leak?
Inside the while loop at 11:17 shouldn't the condition just be temp1 != NULL. temp1->link points to the link that the next node stores. So if the linked list contains only the head and one node temp1->link is NULL because it is the last node and it will not go inside the while loop. So if we want to print the values inside the while loop it won't print anything in this case. Can anyone explain to me?
Why we take pointer variable type as node though memory address can be represented as strings or char type.
Amazing
i have a bit of doubt: Can't we just use the A directly to store the address of new node.
struct node
{
int data;
node *link;
}
node * A;
A=(node *) malloc(sizeof(node));
(*A).data = 2;
(*A).link = NULL;
Is While Statement is correct
How while statement will increment
He speaks good English?
you are doing a = temp every time we create a node so a->next will always be NULL so How are you maintaining the header address?
inteeeeger! sorry I just had to. Thanks this was very helpful 🙂
i am getting confused about the syntax between your use of C & C++ .
why we are not allocating any memory for node *A?
I guess we can add a new node to the linked list in a much better way if we keep a track of the last node ( I call it the tail ) Instead of iterating from head to tail each time .
good
0:23 Oh shit. I thought I would be able to follow along writing my code in JavaScript.
I'be back in a few weeks.
Please come and teach at ubc :(.
Not a right place to advertise, udemy,
I went trough a couple of videos on this topic and this is by far the best imo
didnt understood the traversal part
ur amzing
Thanks
THIS IS GOLD..YOU DESERVE EVERY PENNY I GAVE TO MY COLLEGE
You are assigning data value to the head node and keeping the head node in the video as a node just to mention the starting point of the linked list!
In python it's just two lines of code 🙂
“`
llist = []
for i in range(int(input('enter count: '))):
llist.insert(0, int(input('val: ')))
“`