0% found this document useful (0 votes)
6 views

Data_Structures_Quick_Revision_Notes

This document provides a quick revision of key data structures including stacks, queues, linked lists, and binary search trees, detailing their operations, types, and applications. It also covers searching techniques such as linear and binary search, highlighting their time complexities. The information is structured to facilitate a concise understanding of each data structure and its functionality.

Uploaded by

adityasameer1234
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Data_Structures_Quick_Revision_Notes

This document provides a quick revision of key data structures including stacks, queues, linked lists, and binary search trees, detailing their operations, types, and applications. It also covers searching techniques such as linear and binary search, highlighting their time complexities. The information is structured to facilitate a concise understanding of each data structure and its functionality.

Uploaded by

adityasameer1234
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Data Structures - Quick Revision Notes

STACK (LIFO)

- Operations:

- push(x): Insert at top

- pop(): Remove from top

- peek(): View top element

- Applications:

- Expression evaluation

- Undo features

- Function call stack

- Array-based: Fixed size, easy to implement

- Linked List-based: Dynamic size

QUEUE (FIFO)

- Operations:

- enqueue(x): Add at rear

- dequeue(): Remove from front

- Types:

- Simple Queue

- Circular Queue

- Double-ended Queue (Deque)

- Applications:

- Job scheduling

- Print queue

- Buffer handling

LINKED LIST

- Types:
Data Structures - Quick Revision Notes

- Singly Linked List (next)

- Doubly Linked List (prev & next)

- Circular Linked List (last node connects to first)

- Operations:

- Insert (start, middle, end)

- Delete (by position/data)

- Traverse

- Advantages: Dynamic memory

- Disadvantages: Slow access (no index)

TREE (Binary Search Tree)

- Binary Tree: Max 2 children

- BST (Binary Search Tree):

- Left < Root < Right

- Traversals:

- Inorder: Left, Root, Right (gives sorted output in BST)

- Preorder: Root, Left, Right

- Postorder: Left, Right, Root

SEARCHING TECHNIQUES

- Linear Search:

- Checks each element one by one

- Time Complexity: O(n)

- Binary Search:

- Works only on sorted arrays

- Divide and conquer

- Time Complexity: O(log n)

You might also like