Valid Sudoku - Leetcode 36 - Hashmaps & Sets (Python)

  Рет қаралды 3,454

Greg Hogg

Greg Hogg

6 ай бұрын

The Python code for this problem can be found at my GitHub repo here: github.com/gahogg/Leetcode-So...
Please check my playlists for free DSA problem solutions:
• Array & String Questions
• 2 Pointers Questions
• Sliding Window Questions
• Binary Search Questions
• Stack Questions
• Linked List Questions
• Tree Questions
• Heap Questions
• Recursive Backtracking...
• Graph Questions
• Dynamic Programming (D...
Learn Python and Data Science at mlnow.ai :)
Best Courses for Analytics:
---------------------------------------------------------------------------------------------------------
+ IBM Data Science (Python): bit.ly/3Rn00ZA
+ Google Analytics (R): bit.ly/3cPikLQ
+ SQL Basics: bit.ly/3Bd9nFu
Best Courses for Programming:
---------------------------------------------------------------------------------------------------------
+ Data Science in R: bit.ly/3RhvfFp
+ Python for Everybody: bit.ly/3ARQ1Ei
+ Data Structures & Algorithms: bit.ly/3CYR6wR
Best Courses for Machine Learning:
---------------------------------------------------------------------------------------------------------
+ Math Prerequisites: bit.ly/3ASUtTi
+ Machine Learning: bit.ly/3d1QATT
+ Deep Learning: bit.ly/3KPfint
+ ML Ops: bit.ly/3AWRrxE
Best Courses for Statistics:
---------------------------------------------------------------------------------------------------------
+ Introduction to Statistics: bit.ly/3QkEgvM
+ Statistics with Python: bit.ly/3BfwejF
+ Statistics with R: bit.ly/3QkicBJ
Best Courses for Big Data:
---------------------------------------------------------------------------------------------------------
+ Google Cloud Data Engineering: bit.ly/3RjHJw6
+ AWS Data Science: bit.ly/3TKnoBS
+ Big Data Specialization: bit.ly/3ANqSut
More Courses:
---------------------------------------------------------------------------------------------------------
+ Tableau: bit.ly/3q966AN
+ Excel: bit.ly/3RBxind
+ Computer Vision: bit.ly/3esxVS5
+ Natural Language Processing: bit.ly/3edXAgW
+ IBM Dev Ops: bit.ly/3RlVKt2
+ IBM Full Stack Cloud: bit.ly/3x0pOm6
+ Object Oriented Programming (Java): bit.ly/3Bfjn0K
+ TensorFlow Advanced Techniques: bit.ly/3BePQV2
+ TensorFlow Data and Deployment: bit.ly/3BbC5Xb
+ Generative Adversarial Networks / GANs (PyTorch): bit.ly/3RHQiRj
Become a Member of the Channel! bit.ly/3oOMrVH
Follow me on LinkedIn! / greghogg
Full Disclosure:
Please note that I may earn a commission for purchases made at the above sites! I strongly believe in the material provided; I only recommend what I truly think is great. If you do choose to make purchases through these links; thank you for supporting the channel, it helps me make more free content like this!

Пікірлер: 12
@nguyenkhiem2318
@nguyenkhiem2318 2 ай бұрын
Thanks Greg, you really have a natural talent for teaching. Was struggling with this one
@saedf0
@saedf0 2 ай бұрын
Hey Greg, thanks for the content. Great solution, although i do wonder, how is it BIG O(1) when we have multiple loops? I'm not the best with the complexity identification.
@GregHogg
@GregHogg 2 ай бұрын
Thank you! And that's a great question (at any level). Technically, these loops are going to run a constant amount of times (not dependent on the size of the grid) because WE KNOW the grid will be a 9*9. To scan the grid, it takes exactly 81 positions. Not dependent on some N or something. So O(81) is just O(1) in big o talk. I hope this helps!
@saedf0
@saedf0 2 ай бұрын
@@GregHogg ohhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh /*click moment*/ Man, I cant rely on explanations all the time, do you have any resources/ or easy tricks to remember this stuff. I've tried a few videos and identifying it kindve goes over my head I get that N^2 (for everytime we do this, run these steps) I also understand O(N), Do this Log N (Half each time, divide and conquer but when the code gets a little longer, kindve difficult to track but yh thanks for getting back :)
@mercytum7045
@mercytum7045 4 ай бұрын
Thanks, Greg. This was really helpful!
@GregHogg
@GregHogg 4 ай бұрын
Glad it was helpful!
@nathanaelcheramlak9332
@nathanaelcheramlak9332 4 ай бұрын
Helpful content, Keep going
@GregHogg
@GregHogg 4 ай бұрын
Thanks a ton 😊
@HussainAli-hn2ef
@HussainAli-hn2ef 2 ай бұрын
very helpful, thanks!
@GregHogg
@GregHogg 2 ай бұрын
Glad to hear it!!
@arsheyajain7055
@arsheyajain7055 5 ай бұрын
Super helpful!!!!!
@GregHogg
@GregHogg 5 ай бұрын
Awesome 😎😎
Two Sum - Leetcode 1 - Hashmaps & Sets (Python)
4:25
Greg Hogg
Рет қаралды 11 М.
How I would learn Leetcode if I could start over
18:03
NeetCodeIO
Рет қаралды 351 М.
Эффект Карбонаро и нестандартная коробка
01:00
История одного вокалиста
Рет қаралды 9 МЛН
- А что в креме? - Это кАкАооо! #КондитерДети
00:24
Телеканал ПЯТНИЦА
Рет қаралды 7 МЛН
ОСКАР vs БАДАБУМЧИК БОЙ!  УВЕЗЛИ на СКОРОЙ!
13:45
Бадабумчик
Рет қаралды 6 МЛН
ЧУТЬ НЕ УТОНУЛ #shorts
00:27
Паша Осадчий
Рет қаралды 6 МЛН
Pass Your Next Tech Interview With Valid Sudoku
6:42
Chris Courses
Рет қаралды 17 М.
3Sum - Leetcode 15 - 2 Pointers (Python)
9:42
Greg Hogg
Рет қаралды 6 М.
Valid Parentheses - Leetcode 20 - Stacks (Python)
8:55
Greg Hogg
Рет қаралды 2,9 М.
Top K Frequent Elements - Leetcode 347 - Heaps (Python)
14:08
Greg Hogg
Рет қаралды 4,4 М.
LeetCode 36. Valid Sudoku (Algorithm Explained)
11:33
Nick White
Рет қаралды 97 М.
Python Hash Sets Explained & Demonstrated - Computerphile
18:39
Computerphile
Рет қаралды 111 М.
Sudoku Solver Leetcode || Example + Code + Explanation
24:57
Code with Alisha
Рет қаралды 8 М.
Reverse Linked List - Leetcode 206 - Linked Lists (Python)
8:02
Эффект Карбонаро и нестандартная коробка
01:00
История одного вокалиста
Рет қаралды 9 МЛН