Explain The Difference Between Stack And Linked List Data Structures

Asked By 0 points N/A Posted on -
qa-featured

Please tell the difference between the stack and linked list in simple language? I did not understand their fundamental difference? How they both are different?

SHARE
Answered By 10 points N/A #289457

Explain The Difference Between Stack And Linked List Data Structures

qa-featured

These both are Data Structures. You can think of Stack as a bunch of books placed like the below image.

It represents a stack. As the stack is Last In First Out(LIFO), to get the book, which is on the floor, you have to start from up by taking one by one. That’s how Stack works.
To understand Linked List, just think of train. Just like a train, Linked list has different nodes connected to each other. The formation of their connection depends on which type of Linked list you are implementing. Hope you understand now.

Related Questions