Original post

r/golang - Learn to Implement Stack in Golang

Implement a stack in Golang

Hey Gophers 👋

Wrote a guide on how to implement stacks in Go 👨‍💻

A stack is a linear data structure that follows a particular order named LIFO (Last in First out).

Stacks is mainly used to perform the following operations, all in O(1) time –

  • Push

  • Pop

  • Peek/Top

  • isEmpty

📖 Read here: https://www.mohitkhare.com/blog/stack-in-golang

Feedbacks and improvements are always welcome ✌️