Queue Data Structure & Operations (Linked List Based) | C Programming Example

Queue Data Structure & Operations (Linked List Based) | C Programming Example

Portfolio Courses

1 год назад

18,632 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

@Matheusk0
@Matheusk0 - 06.11.2023 02:11

Hey, I love your tutorials, thanks a lot for you work, pointers and data structures haven been a bit difficult for me to learn but your explanations always help me understand them with ease.

I have a question: At the beginnning when you were defining the Node struct, you defined " typedef struct Node " and then typed "Node" again after the closing curly bracket. Why was the first "Node" needed? Since right after at the Queue struct definition you only set "Queue" once, after the closing curly bracket.

Also, inside the Node struct definition, you used " struct Node *next; " to define the pointer to the next value in the list, and I was wondering if the "struct" word was needed for that, since you already had defined an alias for that struct. Couldn't that line have been just " Node *next; "? Or can we not use aliases when working with pointers?

Thanks a lot again!

Ответить
@anoshiravan6809
@anoshiravan6809 - 03.09.2023 18:35

thank you

Ответить
@doradiv10
@doradiv10 - 28.08.2023 18:23

Thank you very much !
Doing data structures right now in the summer , and this was extremely helpful .
always coming back to this channel for C stuff.

Ответить
@Neberdine
@Neberdine - 02.05.2023 05:23

You are the best. Thanks for all the help you provide.

Ответить
@ivanraulsanchezdiaz7499
@ivanraulsanchezdiaz7499 - 16.04.2023 08:26

What happens if I don't use malloc to create the queue?

Ответить
@laputa4825
@laputa4825 - 26.03.2023 04:56

Hello I have a question,

I want to access structure variables but I have to do it through functions with a "custom" ADT. GET functions will return the requested variable, while SET functions will require the variable being changed and the new value as parameters. While there is a condition that direct access to the structure variables is not allowed outside of the ADT implementation.

How would I approach this? I am very lost. Is there any videos that can help with understanding this?

Ответить
@lawniczakjohn
@lawniczakjohn - 25.03.2023 05:11

Oooh baby! DS&A time.

Anyone discovering this channel for the first time, it’s a great resource.

Ответить
@yigitcoban9823
@yigitcoban9823 - 22.03.2023 22:12

I appreciate the coding sources, If ı miss something which is important, ı can get it from the source code's subtitle. Thank you Mr. Kevin.

Ответить
@saad-jad
@saad-jad - 22.03.2023 17:50

Inside the while loop in the destroy_queue function, you created a temp variable which I think is unnecessary, because currentNode is enough to traverse. Consider this code and correct me if I'm wrong.
while (currentNode !=NULL){
currentNode=currentNode->next;
free(queue->head);
queue->head=currentNode;
} // end of while
I know the difference may not be noticeable, but I think less variables are better.
Love your vids! Have a blessed day.

Ответить
@martinnyagah4313
@martinnyagah4313 - 22.03.2023 17:42

I appreciate the effort you put to teach us! Thank you sir!

Ответить
@dimitrioskalfakis
@dimitrioskalfakis - 22.03.2023 13:44

well thought-out narrative with a comprehensive and clear presentation.

Ответить
@fbi873
@fbi873 - 22.03.2023 13:39

This is an amazing video.
Thanks for your efforts.

Ответить
@wuvorwenda6733
@wuvorwenda6733 - 22.03.2023 11:04

I learned a lot thank you.

Ответить