Count the Number of Complete Components | Multiple Approaches | Leetcode 2685 | codestorywithMIK
Автор: codestorywithMIK
Загружено: 2025-03-21
Просмотров: 7973
Описание:
Whatsapp Community Link : https://www.whatsapp.com/channel/0029...
Disjoint Set Union - • Disjoint Set Union | DSU | Graph Concepts ...
Disjoint Set Union By Rank and Path Compression - • Disjoint Set Union By Rank and Path Compre...
Disjoint Set Union By SIZE and Path Compression - • Disjoint Set Union By SIZE and Path Compre...
Hi Everyone, this is the 71st video of our Playlist "Graphs : Popular Interview Problems".
Now we will be solving a good Graph practice problem - Count the Number of Complete Components | Multiple Approaches | Leetcode 2685 | codestorywithMIK
We will focus on why this is a Graph based problem and why Topological Sort is the ideal approach for this problem.
Problem Name : Count the Number of Complete Components | Multiple Approaches | Leetcode 2685 | codestorywithMIK
Company Tags : AMAZON
My solutions on Github(C++ & JAVA) - https://github.com/MAZHARMIK/Intervie...
Leetcode Link : https://leetcode.com/problems/count-t...
My DP Concepts Playlist : • Roadmap for DP | How to Start DP ? | Topic...
My Graph Concepts Playlist : • Graph Concepts & Qns - 1 : Graph will no m...
My Segment Tree Concepts Playlist : • Segment Tree | Introduction | Basics | Bui...
My Recursion Concepts Playlist : • Introduction | Recursion Concepts And Ques...
Trie Playlist - • Word Search II | Leetcode 212 | Detailed |...
Difference Array Technique: Concepts & Qns : • Introduction | What | How | Difference Arr...
My GitHub Repo for interview preparation : https://github.com/MAZHARMIK/Intervie...
Instagram : / codestorywithmik
Facebook : / 100090524295846
Twitter : / cswithmik
Subscribe to my channel : / @codestorywithmik
╔═╦╗╔╦╗╔═╦═╦╦╦╦╗╔═╗
║╚╣║║║╚╣╚╣╔╣╔╣║╚╣═╣
╠╗║╚╝║║╠╗║╚╣║║║║║═╣
╚═╩══╩═╩═╩═╩╝╚╩═╩═╝
Video Summary :
DFS Approach: This method uses Depth-First Search to traverse the graph and count the number of vertices and edges in each connected component. It then checks if the component forms a complete subgraph by verifying the number of edges.
BFS Approach: This method replaces DFS with Breadth-First Search using a queue. It explores each component level by level, tracking the number of vertices and edges. The completeness condition is checked similarly to the DFS approach.
DSU Approach: This method utilizes Disjoint Set Union (Union-Find) to group connected components efficiently. After forming components, it counts edges within each set and verifies if they satisfy the complete graph condition.
✨ Timelines✨
00:00 - Introduction
0:27 - Motivation
0:52 - Problem Explanation
5:04 - What is Complete Graph ?
9:15 - Approach-1 (DFS)
18:32 - Coding DFS
22:40 - Approach-2 (BFS)
24:32 - Coding BFS
26:37 - Approach-3 (DSU by Size)
40:31 - Coding DSU by Size
#MIK #mik #Mik
#coding #helpajobseeker #easyrecipes #leetcode #leetcodequestionandanswers #leetcodesolution #leetcodedailychallenge #leetcodequestions #leetcodechallenge #hindi #india #coding #helpajobseeker #easyrecipes #leetcode #leetcodequestionandanswers #leetcodesolution #leetcodedailychallenge #leetcodequestions #leetcodechallenge #hindi #india #hindiexplanation #hindiexplained #easyexplaination #interview#interviewtips #interviewpreparation #interview_ds_algo #hinglish #github #design #data #google #video #instagram #facebook #leetcode #computerscience #leetcodesolutions #leetcodequestionandanswers #code #learning #dsalgo #dsa #coding #programming #100daysofcode #developers #techjobs #datastructures #algorithms #webdevelopment #softwareengineering #computerscience #pythoncoding #codinglife #coderlife #javascript #datascience #leetcode #leetcodesolutions #leetcodedailychallenge #codinginterview #interviewprep #technicalinterview #interviewtips #interviewquestions #codingchallenges #interviewready #dsa #hindi #india #hindicoding #hindiprogramming #hindiexplanation #hindidevelopers #hinditech #hindilearning #helpajobseeker #jobseekers #jobsearchtips #careergoals #careerdevelopment #jobhunt #jobinterview #github #designthinking #learningtogether #growthmindset #digitalcontent #techcontent #socialmediagrowth #contentcreation #instagramreels #videomarketing #codestorywithmik #codestorywithmick #codestorywithmikc #codestorywitmik #codestorywthmik #codstorywithmik #codestorywihmik #codestorywithmiik #codeistorywithmik #codestorywithmk #codestorywitmick #codestorymik #codestorwithmik
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: