CS 121 Lecture Notes - Lecture 66: Binary Tree

31 views4 pages

Document Summary

Linear data structures: like lists, a queue & a stack are linear data structures, meaning that the data they represent is organized in a linear fashion. Ex: think about a line of people waiting for a teller at a bjk. A customer enters the queue at the back & moves forward as earlier customers are serviced. Eventually, each customer comes to the front of the queue to be processed. The processing of a queue is conceptual. Stacks: similar to a queue except that its elements go on & come off at the same time. The last item to go on a stack is the first item to come off, like a stack of plate in the cupboard or a stack of hale baless in the barn. Therefore, processes info in a last in, first out (lifo) manner. The java. util package of api contains a class called stack that implements a stack data structure.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents