![Priyanshi Porwal](/img/default-banner.jpg)
- 206
- 44 186
Priyanshi Porwal
India
Registrace 14. 07. 2020
I am a final year undergraduate pursuing my BTech from HBTU Kanpur. I post content related to Data structures and algorithms in C++.
Minimum Substring Partition of Equal Character Frequency | DP |memoization | Biweekly 130 | C++
Minimum Substring Partition of Equal Character Frequency | DP |memoization | Biweekly 130 | C++
zhlédnutí: 274
Video
3143. Maximum Points Inside the Square | Binary Search | Biweekly 130 Editorial | C++
zhlédnutí 286Před 2 měsíci
3143. Maximum Points Inside the Square | Binary Search | Biweekly 130 Editorial | C
506. Relative Ranks | Max Priority Queue | Max Heap | C++ | Hindi
zhlédnutí 232Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/relative-ranks/description Solution Link - github.com/preetu391/LeetCode-daily/blob/main/May 2024/Relative Ranks.cpp Solving daily LeetCode problems is a great way t...
2816. Double a Number Represented as a Linked List | Single Pass | C++ | Hindi
zhlédnutí 127Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/double-a-number-represented-as-a-linked-list/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/May 2024/Double a Number Represented as a Linked List.cpp...
237. Delete Node in a Linked List | Linked List | O(1) solution | C++ | Hindi
zhlédnutí 149Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/delete-node-in-a-linked-list/description/ Solution Link - Its a 2 line code guys Solving daily LeetCode problems is a great way to improve your coding skills! Join m...
881. Boats to Save People | Greedy | C++ | Hindi
zhlédnutí 126Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link-leetcode.com/problems/boats-to-save-people/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/May 2024/Boats to save people.cpp Solving daily LeetCode problems is a...
2441. Largest Positive Integer That Exists With Its Negative | Sorting | C++ | Hindi
zhlédnutí 161Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/largest-positive-integer-that-exists-with-its-negative/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/May 2024/Largest Positive Integer T...
2000. Reverse Prefix of Word | String | Leetcode Easy | C++ | Hindi
zhlédnutí 131Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/reverse-prefix-of-word/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/May 2024/Reverse Prefix of word.cpp Solving daily LeetCode problems...
2997. Minimum Number of Operations to Make Array XOR Equal to K | Bit manipulation | C++ | Hindi
zhlédnutí 279Před 2 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/minimum-number-of-operations-to-make-array-xor-equal-to-k/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/April 2024/Minimum Number of Ope...
3128. Right Triangles | LeetCode Biweekly Contest 129 | C++
zhlédnutí 220Před 3 měsíci
Your one stop for detailed explanation of LeetCode Weekly Contest Solutions from brute force to most optimized. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/contest/biweekly-contest-129/problems/right-triangles/ Solution Link - github.com/preetu391/LeetCode-Contest-Solutions/blob/main/Biweekly Contest 129/Right Triangles.cpp Upsolv...
3127. Make a Square with the Same Color | BiWeekly Contest 129 | C++
zhlédnutí 271Před 3 měsíci
Your one stop for detailed explanation of LeetCode Weekly Contest Solutions from brute force to most optimized. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/contest/biweekly-contest-129/problems/make-a-square-with-the-same-color/ Solution Link - github.com/preetu391/LeetCode-Contest-Solutions/blob/main/Biweekly Contest 129/Make a s...
514. Freedom Trail | Recursion - Memoization - DP | C++ | Hindi
zhlédnutí 458Před 3 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/freedom-trail/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/April 2024/Freedom Trail.cpp Solving daily LeetCode problems is a great way ...
1289. Minimum Falling Path Sum II | Recursion - Memoization - Tabulation - DP | C++ | Hindi
zhlédnutí 188Před 3 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/minimum-falling-path-sum-ii/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/April 2024/Minimum Falling Path Sum II.cpp Solving daily LeetC...
1137. N-th Tribonacci Number | Recursion - Memoization - Tabulation - DP | C++ | Hindi
zhlédnutí 149Před 3 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/n-th-tribonacci-number/description/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/April 2024/nth Tribonacci Number.cpp Solving daily LeetCode problem...
310. Minimum Height Trees | Graph | Topo Sort | BFS | C++ | Hindi
zhlédnutí 190Před 3 měsíci
Your one stop for detailed explanation of LeetCode daily challenges from brute force to most optimized solutions. Whether you're a seasoned programmer or just starting out, this video is for you. Problem Link- leetcode.com/problems/minimum-height-trees/ Solution Link - github.com/preetu391/LeetCode-daily/blob/main/April 2024/Minimum Height Trees.cpp Solving daily LeetCode problems is a great wa...
1971. Find if Path Exists in Graph | Graph | DFS | BFS | Easy | C++ | Hindi
zhlédnutí 133Před 3 měsíci
1971. Find if Path Exists in Graph | Graph | DFS | BFS | Easy | C | Hindi
200. Number of Islands | Graph | DFS | BFS | C++ | Hindi
zhlédnutí 169Před 3 měsíci
200. Number of Islands | Graph | DFS | BFS | C | Hindi
463. Island Perimeter | DFS | BFS | Count number of Islands | Matrix traversal | C++ | Hindi
zhlédnutí 129Před 3 měsíci
463. Island Perimeter | DFS | BFS | Count number of Islands | Matrix traversal | C | Hindi
988. Smallest String Starting From Leaf | Binary Tree | DFS | Recursion | C++ | Hindi
zhlédnutí 172Před 3 měsíci
988. Smallest String Starting From Leaf | Binary Tree | DFS | Recursion | C | Hindi
623. Add One Row to Tree | Binary Tree | Level Order Traversal | C++ | Hindi
zhlédnutí 186Před 3 měsíci
623. Add One Row to Tree | Binary Tree | Level Order Traversal | C | Hindi
3115. Maximum Prime Difference | One pass solution | LeetCode Weekly Contest 393 | C++
zhlédnutí 195Před 3 měsíci
3115. Maximum Prime Difference | One pass solution | LeetCode Weekly Contest 393 | C
3114. Latest Time You Can Obtain After Replacing Characters | Weekly Contest 393 | C++
zhlédnutí 189Před 3 měsíci
3114. Latest Time You Can Obtain After Replacing Characters | Weekly Contest 393 | C
404. Sum of Left Leaves | Binary Tree | O(N) Time | Recursion | C++ | Hindi
zhlédnutí 217Před 3 měsíci
404. Sum of Left Leaves | Binary Tree | O(N) Time | Recursion | C | Hindi
85. Maximal Rectangle | 84. Largest Rectangle in Histogram | Stack | Hard | C++ | Hindi
zhlédnutí 416Před 3 měsíci
85. Maximal Rectangle | 84. Largest Rectangle in Histogram | Stack | Hard | C | Hindi
42. Trapping Rain Water | O(1) space | 2 approaches | Frequently asked | Hard | C++ | Hindi
zhlédnutí 318Před 3 měsíci
42. Trapping Rain Water | O(1) space | 2 approaches | Frequently asked | Hard | C | Hindi
402. Remove K Digits | Stack | Faang Favourite | Interview Question | C++ | Hindi
zhlédnutí 377Před 3 měsíci
402. Remove K Digits | Stack | Faang Favourite | Interview Question | C | Hindi
950. Reveal Cards In Increasing Order | Simulation | Deque | C++ | Hindi
zhlédnutí 620Před 3 měsíci
950. Reveal Cards In Increasing Order | Simulation | Deque | C | Hindi
2073. Time Needed to Buy Tickets | Queue | Linear Time | Constant Space | C++ | Hindi
zhlédnutí 312Před 3 měsíci
2073. Time Needed to Buy Tickets | Queue | Linear Time | Constant Space | C | Hindi
1700. Number of Students Unable to Eat Lunch | LeetCode Easy | Hindi | C++
zhlédnutí 347Před 3 měsíci
1700. Number of Students Unable to Eat Lunch | LeetCode Easy | Hindi | C
3107. Minimum Operations to Make Median of Array Equal to K | Leetcode Weekly 392 Contest | C++
zhlédnutí 131Před 3 měsíci
3107. Minimum Operations to Make Median of Array Equal to K | Leetcode Weekly 392 Contest | C
sorry but very poor explaination i think i have to watch others
Great explanation and very simple code
Thanks you made it easy.. its hell of a task to resume after a gap of 15 days at leetcode
Kaha ho didi ap
bad time complexity
Wow 🔥😍
Better explanation for this question.✨✨
thanks 🙏
done thanks
Nice solution btw
Dp
nice explanation ma'am, i am little confused about subsequence but you just made it easy. So thank you
Why order is not preserved if we start from index 0.
Thanks for clear explanation Priyanshi , I everyday practise seeing your solution.
how many if you watching the solution after getting blank to see this question. You don't even get how to write the recursion???
Nicely explained 🔥
I watch other videos but not able to understand .Dry run part of DP clear all my doubts .Thanks for the explanation .
Thank you for this crisp explanation🙂
Nice explaination
Explanation 👌
Great solution!
Congratulations for 1K 🎉
Understood the concepts so well. Very helpful. Thank you ma'am 👍🏻
What is the proper logic/reasoning to the intuition that you told. Ideally if our strategy is to maximize the capacity usage of every boat (so as to minimize the number of boats), we should be greedy about using max weight with next max weight such that limit condition is satisfied. And indeed this approach gives correct answer but with O(n^2) solution. Not sure what is the proper reasing behind two pointer appoach.
1k soon. 🎉
Yep 😁🚀
Somehow came across this video and iski wajah see I learnt the histogram question and this one. Thanks!
Great Explanation 💯💯
Thank you!
Hi sister, Can you please explain java solution along with your c++ solution ?
Sure in future I definitely will. Actually I don't code in Java that's the reason I don't, and immediately I will not because I am not much familiar with it, but I definitely have plans to do that.
public int minOperations(int[]nums,int k){ for(int num:nums) k^=num; return Integer.bitCount (k); } 🎉❤
Great Explanation 💯💯
Thank you!
Sorry for the bad throat! 🙊
Amazing explanation
Do you use some sort of stylus pen, I too upload Lc solutions but i use pen and paper lol
Yep I use pen tablet
Great Explanation 💯
Great Explanation 💯💯
Ur approach to solving problem good. But difficult to understand. Don't no whether it's speed or high level explanation or writing.. I wanted to learn from u. Hardly I can watch 1 mint bcz I won't understanding
Noted. Will try to improve on this
She has explained it really well!
Thank you@@preetu391
Nice ..
Great Explanation 💯💯
good explanation what is the time and space complexity?
Nice explaination
Well explained!
public int minFallingPathSum(int[][]grid){ int n=grid.length; for(int i=1;i<n;i++){ int p=0,min=grid[i-1][0],nmin=Integer.MAX_VALUE; for(int j=0;j<n;j++) if(grid[i-1][j]<min){ min=grid[i-1][j]; p=j; } for(int j=0;j<n;j++) if(j!=p&&grid[i-1][j]>=min&&grid[i-1][j]<nmin){ nmin=grid[i-1][j]; } for(int j=0;j<n;j++){ if(j!=p) grid[i][j]+=min; else grid[i][j]+=nmin; } } intvans=Integer.MAX_VALUE; for(int i=0;i<grid[0].length;i++) ans=Math.min(ans,grid[n-1][i]); return ans; } Tc=0(n*n); sc=0(1);
Great Explanation 💯💯
why are you not posting videos😢
Posted
Impressive, keep going!
Amazing video and great explanation
nice explanation
Greatest of all other solutions 🙏🏻😊🫂
Great Explanation 💯💯
upload late hua :(