Русские видео

Сейчас в тренде

Иностранные видео


Скачать с ютуб Minimum Height Trees | Know Every Detail | Why BFS | GOOGLE | Leetcode 310 | codestorywithMIK в хорошем качестве

Minimum Height Trees | Know Every Detail | Why BFS | GOOGLE | Leetcode 310 | codestorywithMIK 3 месяца назад


Если кнопки скачивания не загрузились НАЖМИТЕ ЗДЕСЬ или обновите страницу
Если возникают проблемы со скачиванием, пожалуйста напишите в поддержку по адресу внизу страницы.
Спасибо за использование сервиса savevideohd.ru



Minimum Height Trees | Know Every Detail | Why BFS | GOOGLE | Leetcode 310 | codestorywithMIK

Whatsapp Community Link : https://www.whatsapp.com/channel/0029... This is the 48th Video of our Playlist "Graphs : Popular Interview Problems" by codestorywithMIK In this video we will try to solve a very good and famous Graph BFS problem : Minimum Height Trees | Know Every Detail | Why BFS | GOOGLE | Leetcode 310 | codestorywithMIK I will explain the intuition so easily that you will never forget and start seeing this as cakewalk EASYYY. We will do live coding after explanation and see if we are able to pass all the test cases. Also, please note that my Github solution link below contains both C++ as well as JAVA code. Problem Name : Minimum Height Trees | Know Every Detail | Why BFS | GOOGLE | Leetcode 310 | codestorywithMIK Company Tags : GOOGLE My solutions on Github(C++ & JAVA) : https://github.com/MAZHARMIK/Intervie... Leetcode Link : https://leetcode.com/problems/minimum... My DP Concepts Playlist :    • Roadmap for DP | How to Start DP ? | ...   My Graph Concepts Playlist :    • Graph Concepts & Qns - 1 : Graph will...   My Recursion Concepts Playlist :    • Introduction | Recursion Concepts And...   My GitHub Repo for interview preparation : https://github.com/MAZHARMIK/Intervie... Instagram :   / codestorywithmik   Facebook :   / 100090524295846   Twitter :   / cswithmik   Subscribe to my channel :    / @codestorywithmik   Approach Summary : The approach aims to find the minimum height trees in a given undirected graph represented by its nodes and edges. It does so by iteratively removing leaf nodes (nodes with only one neighbor) until there are at most two remaining nodes, which would be the root nodes of the minimum height trees. The key steps involved are: 1. Constructing an adjacency list to represent the graph and calculating the indegree of each node. 2. Enqueuing all leaf nodes (nodes with indegree 1) into a queue. 3. Iteratively dequeuing leaf nodes and reducing the indegree of their neighbors. 4. Removing the dequeued nodes and their adjacent edges from the graph. 5. Repeating steps 2-4 until there are at most two nodes left in the graph. 6. Returning the remaining nodes, which represent the roots of the minimum height trees. This approach efficiently identifies the nodes that form the roots of the minimum height trees by gradually trimming the graph from its outermost layers towards its core. ╔═╦╗╔╦╗╔═╦═╦╦╦╦╗╔═╗ ║╚╣║║║╚╣╚╣╔╣╔╣║╚╣═╣ ╠╗║╚╝║║╠╗║╚╣║║║║║═╣ ╚═╩══╩═╩═╩═╩╝╚╩═╩═╝ ✨ Timelines✨ 00:00 - Introduction 00:19 - Problem Explanation 06:02 - Brute Force 13:02 - Optimal 40:10 - Coding it up #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 #newyear2024

Comments