0% found this document useful (0 votes)
2 views1 page

Complexity

The document outlines various searching and sorting algorithms, including linear search, binary search, and different sorting methods like QuickSort and Merge Sort. It also discusses data structures such as arrays, linked lists, stacks, and queues, along with their operations and complexities. Additionally, it touches on recursion with the Towers of Hanoi puzzle and provides insights into algorithm performance metrics like average and worst-case run times.
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)
2 views1 page

Complexity

The document outlines various searching and sorting algorithms, including linear search, binary search, and different sorting methods like QuickSort and Merge Sort. It also discusses data structures such as arrays, linked lists, stacks, and queues, along with their operations and complexities. Additionally, it touches on recursion with the Towers of Hanoi puzzle and provides insights into algorithm performance metrics like average and worst-case run times.
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/ 1

linear search

binary search Algorithms Analysis

ln ‫ بس املخرج عاوز‬log ‫ عادي يجي بدالها‬ln ‫الـ‬


Heap Sort factorial(n)
‫اما مساحتها بامليموري‬

Insertion at the End (Append)


merge sort Insertion at the Beginning (Prepend)
‫ومساحتها‬ Singly Linked Lists
Searching and Sorting Insertion After an Element

Deleting First Element


Average run time
Insertion at the End (append)
‫مساحتها‬
QuickSort Doubly Linked Lists Insertion at the Beginning (prepend)

Insertion Before an Element


Worst case run time
‫ومساحتها‬ Array & Linked Lists Insertion Before an Element

Selection sort Traversal

insertion sort Singly Linked Lists Searching

bubble sort Deleting Last Element

Deleting a specific element

Traversal
Graphs Complexity Doubly Linked Lists
Deletion

push()

Stack as Array pop()

getTop()

push()
Trees
Stack as Linked list pop()
Stacks
getTop()

worst case pushing full ‫ كان‬stack ‫إذا الـ‬

getHead()
Queue As Array
enqueue()
Towers of Hanoi puzzle Recursion
getHead()

Queue As Circular Array enqueue()

dequeue()

getHead()
Queues Queue As Linked List enqueue()

dequeue()

Queue As Array dequeue()

Priority Queues ‫التوتل تايم للـ‬

You might also like