aboutsummaryrefslogtreecommitdiff
path: root/mindmap/stack.org
diff options
context:
space:
mode:
authorPreston Pan <preston@nullring.xyz>2024-06-28 21:30:42 -0700
committerPreston Pan <preston@nullring.xyz>2024-06-28 21:30:42 -0700
commite7dd5245c35d2794f59bcf700a6a92009ec8c478 (patch)
tree0d0e81552f0426f8b715bd5bd3bdd0856058db2c /mindmap/stack.org
parent01ba01763b81a838dcbac4c08243804e068495b9 (diff)
stuff
Diffstat (limited to 'mindmap/stack.org')
-rw-r--r--mindmap/stack.org7
1 files changed, 7 insertions, 0 deletions
diff --git a/mindmap/stack.org b/mindmap/stack.org
index 74d0138..9f05a5e 100644
--- a/mindmap/stack.org
+++ b/mindmap/stack.org
@@ -4,3 +4,10 @@
#+title: stack
#+author: Preston Pan
#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+* Introduction
+A stack in programming is a data structure that satisfies the following API rules:
+1. Push: puts something on the top of the stack
+2. Pop: takes item off stack and gives it to the caller
+3. Peek: hands copy of top item on the stack to caller
+4. isEmpty: checks if the stack size is zero
+where stacks generally store their data in a list, either an array or a singly linked list.