LeetCode 1561. Maximum Number of Coins You Can Get - Interview Prep Ep 92

preview_player
Показать описание


⭐ Support my channel and connect with me:

Algorithm explained:
We can sort the give piles array first, then we keep taking the second biggest value from the right end and keep tracking the count of coins that we have collected along the way, once we have reached n coins, we can just break out.

// TOOLS THAT I USE:

// MY FAVORITE BOOKS:

My ENTIRE Programming Equipment and Computer Science Bookshelf:

And make sure you subscribe to my channel before you leave!

Your comments/thoughts/questions/advice will be greatly appreciated!

#softwareengineering #leetcode #algorithms #coding #interview #SDE #SWE #SiliconValley #programming #datastructures
Рекомендации по теме
Комментарии
Автор

Wonderful! I wonder why there are so few views in such quality videos..

reachrishav
Автор

Can you please explain this code in Python. That will be very help full for me

Kumar