
Rishi Kumar
@RishiKumarSRK
Followers
208
Following
359
Media
124
Statuses
416
| Tech enthusiast 🚀 | MERN Stack, Game Developer | Talks about AI, startups, software development, tech and innovation 💻 and shitposting |
Joined June 2023
This Problem 🫡. Initially thought this was a Math one, but then went through the discussions and figured out this is a graph one , .Then creating the adjacency list and then BFS . Just Wow, everyone please try to solve this one . #LeetCode
0
0
3
Removed. store the max pattern and then use a stack and check for the max pattern and keep track of the sum.Now for the remaining elements in the stack check for the min pattern and keep on adding to the prev sum . return the sum . #LeetCode
0
1
5
Erased 😎. Have a map if the element not in the map add it , else find the prev occurence and remove the elements until it .Have the curr_sum in stored in the process and return the max sum . #Leetcode
0
1
3
Walls and Gates . The key idea here is to starting BFS at multiple points , multi-source BFS to be precise. Push all the gates into the queue and start bfs simultaneously .#Neetcode
1
0
2