DSA (BUBBLE SORT SLIDES ), Slides of Data Structures and Algorithms

his document contains well-structured and easy-to-understand slides on the Bubble Sort Algorithm, designed for university students and beginners in computer science. 📌 What’s included: Introduction to Bubble Sort Step-by-step working explanation Flowchart representation Algorithm (pseudocode) Time and space complexity analysis Best, worst, and average case explanation Advantages and disadvantages Solved example for better understanding 📊 The slides are clean, visually appealing, and suitable for: Exam preparation Viva and presentations Quick revision 💡 Perfect for students studying Data Structures, Algorithms, or Programming Fundamentals. ✔️ Simple language ✔️ Beginner-friendly explanation ✔️ Ready-to-use for presentations Download now to understand Bubble Sort quickly and effectively!

Typology: Slides

2025/2026

Available from 03/29/2026

aruhi-choudhary
aruhi-choudhary 🇮🇳

1 document

1 / 28

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Faculty
School of Engineering & Technology
K.R. Mangalam University
Data Structure
Dr Swati Gupta & Ms Suman
Unit 4 : Sorting and Searching
Dr. Swati & Ms Suman
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c

Partial preview of the text

Download DSA (BUBBLE SORT SLIDES ) and more Slides Data Structures and Algorithms in PDF only on Docsity!

Faculty School of Engineering & Technology K.R. Mangalam University

Data Structure

Dr Swati Gupta & Ms Suman

Unit 4 : Sorting and Searching

Dr. Swati & Ms Suman

Session Agenda ➢ Applications of Sorting in Real World ➢ Basic Introduction of Sorting ➢ Bubble Sort ➢ Algorithm and Complexity Analysis of Bubble Sorts ➢ Brainstorming Session ➢ Insertion sort ➢ Algorithm and Complexity Analysis of Insertion sort ➢ Example of Insertion Sort ➢ Brainstorming Session Session 32 : Introduction to Sorting Session 33 :Insertion Sort

Session Agenda ➢ Divide and Conquer Strategy ➢ Merge Sort ➢ Example of Merge Sort ➢ Algorithm of Merge Sort ➢ Complexity Analysis of Merge Sort ➢ Brainstorming Session ➢ Quick Sort ➢ Choosing the pivot element in Quick Sort ➢ Example of Quick Sort ➢ Algorithm of Quick Sort ➢ Complexity Analysis of all the Sorting Algorithm ➢ Brainstorming Session Session 36: Merge Sort Session 37: Quick Sort

Session Agenda ➢ Linear Search ➢ How to search an Element ➢ Example of Linear Search ➢ Algorithm of Linear Search and Its Applications ➢ Complexity Analysis of the Linear Search ➢ Brainstorming Session ➢ Binary Search ➢ How to search an Element ➢ Example of Binary Search ➢ Algorithm of Binary Search and Its Applications ➢ Complexity Analysis of the Binary Search ➢ Brainstorming Session Session 38 : Linear Search Session 39 :Binary Search

Session 32 ➢ Basic Introduction of Sorting ➢ Applications of Sorting in Real World ➢ Bubble Sort ➢ Algorithm and Complexity Analysis of Bubble Sorts ➢ Brainstorming Session INTRODUCTION TO SORTING

Basic Introduction of Sorting ➢ In data structure, we often need to rearrange elements of our data on basis of increasing/decreasing order to perform our key operation. This process of rearrangement is called Sorting. ➢ Sorting data allows a user to find information faster and easier.

Applications of Sorting in Computer ScienceDatabase Management : Sorting is crucial for efficient querying and indexing in databases. ➢ Machine Learning : Sorting is used in preprocessing steps for feature scaling and normalization. ➢ Parallel Computing : Sorting algorithms are fundamental in parallel computing for tasks like load balancing and task scheduling

Types of Sorting Source : https://techvidvan.com/tutorials/wp- content/uploads/sites/2/2021/06/TechVidvan-Bubble-sort- normal-image01.jpg.

Real World Application of Bubble Sort

Example of Bubble Sort Let's take an array of 5 elements. int arr[5] = {50, 25, 5, 20, 10}

Example of Bubble Sort

Example of Bubble Sort

Bubble Sort Algorithm

  • declare variables i, j
  • loop : i = 0 to n – 1 // outer loop
    • loop : j = 0 to n - i- 1 // inner loop
      • if ( a[j]>a[j+1] ) then
        • swap a[j] & a[j+1]
    • end loop // inner loop
  • end loop // outer loop

Bubble Sort Algorithm Complexity Analysis