Link to article:
Look at this:
Why is this:
(I had to use 2 images for each sentence since the sentences are on two different lines(I can only screenshot a square).
Examine the two terms and how they behave. A queue is first on, first off. A stack is last on, first off.
I know but how are queues and stacks suitable for breadth-first search and depth-first search?
It’s in how we build and retrieve the different data structures. One is going across then down, the other is going down then across. That’s as much as I can go into it. The rest is up to you to explain to me.
I’m just going to take the articles and lessons to understand it.