Это видео недоступно.
Сожалеем об этом.

Sorting In One Shot C++ | Bubble, Insertion, Selection Sort | Complete DSA Course 2023 | Placements

Поделиться
HTML-код
  • Опубликовано: 21 окт 2023
  • 🌐 Telegram : telegram.me/pw_collegewallah Click Here To Enroll 👇
    📚 Decode Data Science with ML 1.0 - bit.ly/489C5Vx
    📚 Decode Full Stack Web Dev 1.0 - bit.ly/3uEFb56
    📚 Decode Java+DSA 1.0 - bit.ly/46w8a8z
    Job Assurance Programs
    📚 Full stack Data Science Pro - bit.ly/3uy5H09
    📚 Full Stack Web Development - bit.ly/3T4X8nT
    📚 Mastering Full Stack Data Analytics - bit.ly/3QVjKnZ
    📚 Building Microservices in Java for Cloud - bit.ly/3SU4fPO In this video, we're going to be learning how to sort items in one shot using the Bubble, Insertion, and Selection Sort algorithms.
    This is a complete course that covers everything you need to know to sort items in one shot using the C++ programming language. After watching this video, you'll be able to use the Bubble, Insertion, and Selection Sort algorithms in one shot!
    🌐 Click Here To enroll:-
    📚Decode + Java 1.0 :- physicswallah.onelink.me/ZAZB...
    📚Decode Full Stack Web Dev 1.0 :- physicswallah.onelink.me/ZAZB...
    📚Decode Data Science With Machine Learning 1.0 : -physicswallah.onelink.me/ZAZB...
    -----------------------------------------------------
    📲 PW App/Website: physicswallah.onelink.me/ZAZB...
    🌐 PW Skills Website: pwskills.com/
    -------------------------------------------------------
    📌 COLLEGE WALLAH SOCIAL MEDIA-
    🌐 Instagram: pwcollegewallah...
    -------------------------------------------------------
    📌 RECOMMENDED CHANNELS FOR YOU -
    🌐 Physics Wallah - Alakh Pandey: / @physicswallah
    🌐 PW Skills Tech: / @pwskillstech
    🌐 JEE Wallah: / @pw-jeewallah
    🌐 JEE Challengers by PW : / @jeechallengersbypw
    🌐 GATE Wallah : / @gatewallahbypw
    🌐 GATE Wallah - EC,EE & CS : / @gatewallah_ee_ec_cs
    🌐 GATE Wallah - ME, CE & XE : / @gatewallah_me_ce_xe
    🌐 GATE English : / @gatewallahenglish
    -------------------------------------------------------
    📌 PHYSICS WALLAH SOCIAL MEDIA -
    🌐 Telegram: t.me/Physics_Wallah_Official_...
    🌐 Facebook: / physicswallah
    🌐 Instagram: / physicswall. .
    🌐 Twitter : / physics__wallah
    🌐 Linkedin: / 7808. .
    -------------------------------------------------------
    Sorting In One Shot C++ | All Sorting Algorithms | Complete DSA Course 2023 | Interview / Internship
    Sorting In One Shot C++ | Bubble, Insertion, Selection Sort | Complete DSA Course 2023
    📌 For any Queries or Complaints visit: bit.ly/PW_Queries OR give a Missed Call on 07019-243-492

Комментарии • 30

  • @Factroller69
    @Factroller69 9 месяцев назад +16

    3:05 bubble sort
    39:17 question 1
    42:38 question 2
    53:12 selection sort
    1:18:42 question 3
    1:19:20 insertion sort

  • @ishagopinath
    @ishagopinath 9 месяцев назад +41

    Please make one shot on OOPS, Linked List, Stack, Queue, Trees as well..

  • @serenasinha5431
    @serenasinha5431 7 месяцев назад +10

    🎯 Key Takeaways for quick navigation:
    00:56 ⏱️ *Time complexity analysis and optimization strategies for sorting algorithms will be discussed.*
    02:05 🤔 *Sorting challenges may involve choosing between ascending, descending, or non-decreasing order.*
    03:55 🧩 *Introduction to advanced sorting algorithms like Merge Sort, Quick Sort, and others.*
    05:16 🤔 *Explanation of a manual sorting algorithm using the "pass" method and swapping elements.*
    08:10 🔄 *Sorting involves comparing and swapping adjacent elements to arrange them in ascending order.*
    09:55 🔄 *Verification step: Ensure each element is in the correct position after the sorting process.*
    11:30 🔄 *Swapping in sorting algorithms involves comparing adjacent elements and swapping them if they are in the wrong order.*
    20:07 🔄 *The speaker explains a loop structure using the variable "i" and mentions the need to iterate from "i" to "n-1" in a sorting algorithm.*
    22:07 🔄 *The speaker suggests that the time complexity of Bubble Sort is approximately n*(n+1)/2, explaining the reasoning behind this calculation.*
    24:18 🔄 *Summing up the total number of operations in Bubble Sort, the speaker arrives at a formula: n*(n-1)/2, providing a mathematical understanding of the time complexity.*
    28:19 ✅ *Checking for swaps in each pass and stopping when no swaps occur is a practical optimization for bubble sort.*
    32:27 📐 *To check if an array is already sorted, a boolean flag and element-wise comparisons are employed.*
    33:14 ⏩ *Average and worst cases in sorting have complexities of O(n^2), making them less efficient.*
    33:42 💡 *Understanding worst case: Number of operations in the worst case is approximately n * (n-1)/2.*
    34:13 🔄 *Differentiating stable and unstable sorting: Stable sorting preserves the relative order of equal elements.*
    36:53 🔄 *Bubble sort optimization discussed.*
    37:30 🌐 *Comparison of two elements in bubble sort.*
    37:47 ⭐️ *Example of swapping in bubble sort.*
    38:00 💡 *Explanation of bubble sort stability.*
    39:16 ❓ *Addressing questions about maximum swaps needed to sort an array.*
    41:14 🔄 *In sorting, understanding the worst-case scenario helps optimize algorithms.*
    41:41 🔄 *Analyzing the number of swaps in sorting algorithms helps determine efficiency.*
    45:22 📊 *To solve a question related to arranging positive elements in a relative order (e.g., 5 2 3 4 1), create a new array or vector, and insert non-zero elements as they appear.*
    46:17 ⚖️ *Maintaining stability in Bubble Sort: Swap elements only if the element at index i is greater than the element at index i + 1.*
    47:26 🧹 *Optimize Bubble Sort by pushing the maximum element to the last position, reducing unnecessary comparisons.*
    48:10 🔄 *Implement swapping in Bubble Sort by checking if the current element is zero and swapping it with the adjacent non-zero element.*
    51:17 🔄 *Modify Bubble Sort code to handle zero elements more efficiently.*
    57:57 🔄 *Explaining the logic of the selection sort process, iteratively moving the lowest unsorted element to the front.*
    59:16 🔄 *Discussing the looping mechanism for iterating through the array and implementing simple indexing for the selection sort algorithm.*
    59:56 🔄 *To find the minimum element in an array, iterate through the array, keeping track of the minimum element and its index.*
    01:00:39 🔄 *Utilize the concept of the minimum index to efficiently swap elements without unnecessary steps.*
    01:00:54 🛠️ *Implementing the logic for finding the minimum index in the sorting algorithm is straightforward and crucial.*
    01:01:34 🔍 *Demonstrating how to find the minimum element and its index in an array using C++.*
    01:02:17 🤔 *Explaining the rationale behind initializing the minimum index variable to -1 in the sorting algorithm.*
    01:02:30 🔄 *Utilizing the minimum index variable to store the index of the minimum element during the array traversal.*
    01:03:35 🔄 *Selection Sort algorithm explanation begins, focusing on minimum element and swapping.*
    01:04:15 🔄 *Attention to the inner loop, using an integer j from i to n-1 in the Selection Sort.*
    01:05:09 🔄 *Demonstrates the swapping process in Selection Sort, ensuring the first element in the red box is the minimum.*
    01:05:36 🔄 *Explains the logic behind the loop for the red box in Selection Sort, focusing on the 'j' loop.*
    01:06:23 🔄 *Introduces conditions for swapping in Selection Sort based on the minimum element.*
    01:06:36 🔄 *Explains the need for 'j' inside the loop, managing the number of passes in Selection Sort.*
    01:06:50 🔄 *Discusses the logic behind the loop and tasks performed outside the loop in Selection Sort.*
    01:07:43 🐛 *Be cautious with variable names; a coding bug occurred due to a typo (j = ज instead of j = i).*
    01:08:26 🤔 *Emphasis on coding independently; spoon-feeding can hinder understanding and career growth.*
    01:08:55 🔴 *Creating a red box visually illustrates the shifting elements in the sorting process.*
    01:09:08 ⚙️ *Overview of the selection sort algorithm, including swapping elements and its time and space complexity.*
    01:09:23 🔄 *Calculating the number of operations in the selection sort algorithm based on loop iterations and array size.*
    01:09:49 🤓 *Understanding the number of operations in selection sort: approximately n * (n - 1) / 2 comparisons and swaps.*
    01:10:19 🔄 *A simplified explanation of the number of operations, breaking down the outer and inner loop iterations.*
    01:11:14 🔄 *In the worst case, the total number of operations in sorting can be calculated as n * (n-1) / 2.*
    01:11:26 🔄 *The total time complexity of sorting algorithms is related to the number of operations performed, and it can be expressed as O(n^2).*
    01:12:06 🤔 *The speaker suggests watching further lectures for a detailed explanation of why the time complexity is O(n^2) and not explained here.*
    01:12:26 🔄 *Optimizing bubble sort involves using a boolean flag to check if any swaps are made in a pass, reducing the best-case time complexity to O(n).*
    01:13:21 🔄 *The number of swaps in selection sort is determined by the maximum possible swaps, which is n-1 swaps in the worst case.*
    01:14:17 🔄 *Selection sort is considered better than bubble sort because of fewer swaps in the best case and no additional space complexity.*
    01:15:10 🔄 *Selection Sort has a disadvantage related to the number of swaps, impacting associated costs.*
    01:15:39 🔄 *Bubble Sort is stable, unlike Selection Sort, ensuring the order remains the same for equal elements after sorting.*
    01:15:54 🧹 *After sorting, the order of equal elements should be maintained for stability.*
    01:16:07 🔄 *Selection Sort swaps the first element with the minimum element in each iteration.*
    01:16:22 🔄 *The algorithm for Selection Sort involves swapping elements to place the minimum element at the beginning.*
    01:16:50 🔄 *Demonstrates the swapping of elements in Selection Sort using a specific example.*
    01:17:40 🔄 *Addresses the challenge of ensuring stability in Selection Sort and the need for careful consideration.*
    01:18:23 🔄 *Stresses the significance of stability for dependable sorting results, using the example of Selection Sort.*
    01:19:30 ⏱️ *Insertion Sort is better than Bubble Sort, with similar time complexity but better in practice.*
    01:20:11 🃏 *Understanding Insertion Sort through playing cards: sorted and unsorted parts.*
    01:26:06 🔄 *Passes in Sorting Algorithms: Mention of the number of passes required for sorting, specifically in Bubble and Insertion Sort.*
    01:27:59 🔄 *Comparing and Swapping Elements: Clarifies the comparison strategy in Insertion Sort, emphasizing comparing with the left index and swapping until the correct position is found.*
    01:28:51 🚦 *Loop Termination Conditions: Highlights the loop termination conditions in Insertion Sort, ensuring that the algorithm executes correctly and avoids errors.*
    01:32:43 🔄 *Explains the condition for swapping elements based on the comparison of array values at indices j and j-1.*
    01:33:13 🔄 *Describes the loop termination condition, ensuring the algorithm proceeds until the entire array is sorted.*
    01:34:30 🔄 *The lecture discusses loop conditions and array manipulation in the context of sorting algorithms in C++.*
    01:34:45 🧐 *The instructor swaps elements until finding one greater than 20 in insertion sort, highlighting a key feature of this algorithm.*
    01:35:12 🔍 *The lecture emphasizes that the insertion sort algorithm efficiently handles already sorted arrays.*
    01:36:05 🔄 *The algorithm's efficiency is demonstrated, emphasizing the minimal number of operations required.*
    01:37:03 🔀 *A pre-sorted array efficiently skips the inner loop, saving unnecessary iterations in insertion sort.*
    01:39:10 🔄 *Demonstrating the stability of insertion sort by maintaining the order of equal elements during sorting.*
    01:39:49 🤔 *A question is posed about which sorting technique should be used in a player's deck of cards.*
    Made with HARPA AIg

  • @bilalarshad2092
    @bilalarshad2092 9 месяцев назад +7

    Thanku Sir,
    Sir plzz make video on Structures, File Handling and OOPs.
    Plzz Sir.

  • @CollegeSemesters
    @CollegeSemesters 9 месяцев назад +3

    Thank You Sir For Sharing This Video

  • @carnivalking8824
    @carnivalking8824 9 месяцев назад +3

    Make one shot on all type of sorting so that we do revision including merg sort ,heap sort and all of these and same on searching as well

  • @Abhishek-qx9zg
    @Abhishek-qx9zg 9 месяцев назад +2

    Thanks sir ji 😊😊😊😊😊😊

  • @alienkid
    @alienkid 9 месяцев назад

    Teaching in two languages at the same time is impressive

  • @onlyforu1819
    @onlyforu1819 9 месяцев назад

    Your teaching style is very nice.
    I am from Nepal and i always watch raghav sir videos because of his teaching style...
    Keep doing and keep growing sir,

  • @shravanbharti2336
    @shravanbharti2336 8 месяцев назад

    Sir Please upload other Sorting algos merge ,quick and other ...sir plaese ,
    sir your explaination technique is too good and unique .
    So please sir Upload as soon as possible 🙏🙏🙏

  • @drone231
    @drone231 8 месяцев назад +1

    26:00

  • @Gurpreet11g
    @Gurpreet11g 8 месяцев назад

    Sir please upload your video on binary search

  • @bhavikbansiwal5304
    @bhavikbansiwal5304 7 месяцев назад +1

    Full DSA course with implementation 🙏🙏🙏

  • @Abhishek-qx9zg
    @Abhishek-qx9zg 9 месяцев назад +1

    Sir please Linked list pura detail me dalna please 🥺❤️❤️🥺

  • @Mkhan-jf6ri
    @Mkhan-jf6ri 8 месяцев назад

    Provide Linked list lectures

  • @torretogaming5167
    @torretogaming5167 9 месяцев назад +1

    Raghav sir pls ek video classes and reference pr bana do❣️❣️❣️❣️❣️❣️

  • @Abhishek-qx9zg
    @Abhishek-qx9zg 9 месяцев назад +1

    1:40:49 maja aa gaya 😊😊😊😊😊😊❤❤❤❤❤❤

  • @itsrohan1001
    @itsrohan1001 7 месяцев назад +2

    Notes

  • @VijaykumarNishad-lm9sc
    @VijaykumarNishad-lm9sc 4 месяца назад

    Sir quick sort aur merge sort ki video bhi chahiye

  • @RAHULYADAV-em3wq
    @RAHULYADAV-em3wq 9 месяцев назад

    ❤❤❤❤❤❤❤❤

  • @msrishti2684
    @msrishti2684 9 месяцев назад

    *please keep your thumbnails*
    *PLAIN AND PRECISE* 💯

  • @ajay.....07
    @ajay.....07 Месяц назад +1

    Sir, Mujhe Ab pta chlaa ki Mujhe Spoon Feeding H 😭😭

  • @Robert_austia
    @Robert_austia 9 месяцев назад +1

    Please help me to buy laptop 😢😢
    Under 40k 😢😢 please help me

  • @anujjadhav5398
    @anujjadhav5398 9 месяцев назад +1

    Please suggest me best gaming laptop under 1 lakh excluding Acer,MSI & Lenovo