Detonate the Maximum Bombs || Math || Graph || How to think of Graph || Leetcode 2101

  Рет қаралды 4,559

Aryan Mittal

Aryan Mittal

Күн бұрын

In this video, I'll talk about how to solve the problem - Leetcode 2101. Detonate the Maximum Bombs
Problem Link: leetcode.com/problems/detonat...
C++/Java/Python Code & Notes: drive.google.com/file/d/1ii_a...
Detonate the Maximum Bombs || Math || Graph || How to think of Graph || Leetcode 2101
Let's Connect:
📝Linkedin: / aryan-mittal-0077
📸 Instagram: / aryan_mittal_007
📱Telegram : t.me/aryan_mittal_group
🤖 Github: github.com/aryan-0077
🛍️ Products I use in Videos: (✨ Marked for Mostly requested Products)
Main Camera (Canon 200D ii): amzn.to/41cfS5h
Vlog Camera (iphone 13): amzn.to/42aOJRh
Tripod for Lectures: amzn.to/3HMoloF
Tripod for Vlogs: amzn.to/44wGL6L
✨Mic: amzn.to/41bj8gU
Shadow Multi Colour Light: amzn.to/41bmIrq
Main Light: amzn.to/3LF6BNb
Tripod for Lights: amzn.to/3LFcQAt
Softbox for Lights: amzn.to/42mHqWE
✨My Pen Tablet for Notes: amzn.to/44A61ZJ
✨New Tablet for Notes: amzn.to/44BjTDa
Tablet Stand: amzn.to/3NMFIJR
Power Bank: amzn.to/421yHsZ
✨USB Hub: amzn.to/3p8NGTf
✨HardDisk to store Lectures: amzn.to/3HKafEs
✨My Laptop: amzn.to/44w12ct
✨My Monitor: amzn.to/3LCG6YL
My UPS: amzn.to/3Lydy2y
My UPS old: amzn.to/3LXT0C3
✨My Mouse: amzn.to/3LYmJdY
✨My Keyboard: amzn.to/3NJs4ah
Resources you can try:
Learn Coding: • Complete RoadMap for C...
🎥Channel Playlists
🎥 Baap Graph Series - by Aryan: • Baap Graph Series - by...
🎥Dynamic Programming: • Complete Dynamic Progr...
🎥Bit Manipulation: • Complete BIT MANIPULAT...
🎥Mathematics for DSA: • Complete Mathematics f...
🎥Leetcode Top Interview Questions: • FAANG & Leetcode Inter...
🎥Codeforces Problem B Ladder: • Complete PROBLEM B LAD...
🎥Codeforces Problem C Ladder: • Codeforces PROBLEM C L...
🎥Codeforces Problem D Ladder: • Complete PROBLEM D LAD...
🎥 Top 150 Interview Questions: • Top 150 Interview Ques...
🎥 Complete Array Problem Playlist: • Complete Array Intuit...
🎥 Complete Binary Search Problem Playlist: • Complete Binary Search...
🎥 Complete Stack Playlist: • Complete Stack & Queue...
🎥 Complete Graph Problem Playlist: • Complete Graph Intuiti...
🎥 Complete TREE Playlist: • Complete TREE Intuitio...
🎥 Complete DP Problem Solving: • Complete DP Intuition ...
🎥 Complete Linked List: • Complete Linked List I...
🎥 Complete Greedy Problem Playlist: • Complete Greedy Intui...
🎥 Complete Divide & Conquer Algorithm Playlist: • Complete Divide & Conq...
🎥 Complete Trie Playlist: • Complete Trie Intuitio...
🎥 Complete Mathematics & Number Theory Problems: • Complete Mathematics &...
About Channel:
We teach about how you can grow in life & educate about programming in Fun & Intuitional way.
About Me:
I am Aryan Mittal - a Software Engineer, Speaker, Creator & Educator. During my free time, I create programming education content on this channel & also how to use that to grow :)
✨ Timelines✨
0:00 - Problem Explanation
4:17 - Intuition
7:40 - Logic & Solution
11:03 - Code Explanation
✨ Hashtags ✨
#programming #Interviews #leetcode #faang #maang #datastructures #algorithms

Пікірлер: 19
@ARYANMITTAL
@ARYANMITTAL Жыл бұрын
C++/Java/Python Code & Notes: drive.google.com/file/d/1ii_a9zN5r10KwyfG61BVPtMeb8Lakw4m/view?usp=sharing Were you able to figure out if it was a Graph Problem ?? If yes, then what triggered that intuition 🙈??
@Mr.Potato23
@Mr.Potato23 Жыл бұрын
random exam question in pakistani college.
@user-fv6et2qm7i
@user-fv6et2qm7i Жыл бұрын
Just amazing bro ❤❤
@aorusgaming5441
@aorusgaming5441 Жыл бұрын
best
@vaibhavchaubey8373
@vaibhavchaubey8373 Жыл бұрын
your explanation is toooo good bro!
@sanskarkumar7285
@sanskarkumar7285 Жыл бұрын
very easy explanation. thanku sir
@tejaswijadhav8031
@tejaswijadhav8031 Жыл бұрын
Nice explanation sir
@user-fu4mw8no5t
@user-fu4mw8no5t Жыл бұрын
nice
@rudrikasingh2892
@rudrikasingh2892 Жыл бұрын
Great solution ! Though one doubt. Why in the java solution we are using an array to count number of visited states?
@ce063_gautamlathiya5
@ce063_gautamlathiya5 Жыл бұрын
class Solution { private: void dfs(int node, vector adj, vector &vis, int &cnt){ vis[node] = 1; cnt++; for(auto i : adj[node]){ if(!vis[i]){ dfs(i,adj,vis,cnt); } } } public: int maximumDetonation(vector& bombs) { int n = bombs.size(); vector adj(n, vector()); for(int i = 0; i < n; i++){ for(int j = 0; j < n; j++){ if(i != j){ long long h = bombs[i][0], k = bombs[i][1], r = bombs[i][2]; long long x = bombs[j][0] - h, y = bombs[j][1] - k; if((x*x + y*y)
@tejuschaturvedi6234
@tejuschaturvedi6234 Жыл бұрын
pass adj by reference in parameters
@harshal8781
@harshal8781 Жыл бұрын
bro want a logic 🤗🤗
@farnazzinnah8541
@farnazzinnah8541 Жыл бұрын
not watching any other YT videos from now on. Only Aryan's videos. Because he taught me this hard concept in the easiest way possible. I don't think so anyone else can explain as good as him. Thanks man!
@biswaMastAadmi
@biswaMastAadmi 6 ай бұрын
zyada ho gya
@ashishdhal4614
@ashishdhal4614 Жыл бұрын
Largest island problem with a bit of 8 grade math
@summerkoushal679
@summerkoushal679 Жыл бұрын
bro you always succeed to tell the visualisation of intuition, no one can do this good. You are a gem of a guy 🫀
@PrajwalRaut
@PrajwalRaut Жыл бұрын
Sir thoda Hindi mai bhi baate krte jau
@VishalKumar-uk5uc
@VishalKumar-uk5uc Жыл бұрын
Bhiya Hindi and English please
@aditimahabole1761
@aditimahabole1761 Жыл бұрын
your explanation is toooo good bro!
Detonate the Maximum Bombs - Leetcode 2101 - Python
11:20
NeetCodeIO
Рет қаралды 12 М.
A clash of kindness and indifference #shorts
00:17
Fabiosa Best Lifehacks
Рет қаралды 111 МЛН
Scary Teacher 3D Nick Troll Squid Game in Brush Teeth White or Black Challenge #shorts
00:47
ЧУТЬ НЕ УТОНУЛ #shorts
00:27
Паша Осадчий
Рет қаралды 8 МЛН
ArcGIS Maps SDK for JavaScript: Key Highlights of the Last Year
1:00:58
My Brain after 569 Leetcode Problems
7:50
NeetCode
Рет қаралды 2,5 МЛН
The Algorithm Behind Spell Checkers
13:02
b001
Рет қаралды 408 М.
I Melted Wood With Friction
8:44
The Action Lab
Рет қаралды 925 М.
Why algorithms are called algorithms | BBC Ideas
3:09
BBC Ideas
Рет қаралды 2,7 МЛН
New Recipe for Pi - Numberphile
14:29
Numberphile
Рет қаралды 265 М.
The Black Box Method: How to Learn Hard Concepts Quickly
14:09
Colin Galen
Рет қаралды 1,1 МЛН
DETONATE THE MAXIMUM BOMBS | LEETCODE 2101 | PYTHON GRAPH SOLUTION
11:12
A clash of kindness and indifference #shorts
00:17
Fabiosa Best Lifehacks
Рет қаралды 111 МЛН