Stacks: push() pop() peek() search() (Java)

Stacks: push() pop() peek() search() (Java)

Author: Nathan Schutz
See More
Try a College Course Free

Sophia’s self-paced online courses are a great way to save time and money as you earn credits eligible for transfer to over 2,000 colleges and universities.*

Begin Free Trial
No credit card required

28 Sophia partners guarantee credit transfer.

264 Institutions have accepted or given pre-approval for credit transfer.

* The American Council on Education's College Credit Recommendation Service (ACE Credit®) has evaluated and recommended college credit for 22 of Sophia’s online courses. More than 2,000 colleges and universities consider ACE CREDIT recommendations in determining the applicability to their course and degree programs.


A look at how Stacks fit into the Java Collections Framework, how they work at an abstract level, how they work in the Java programming language, and the methods push, pop, peek and search of the Stack class.