Skip to content

Latest commit

 

History

6,006 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeetCode

Documenting my LeetCode journey one problem at a time.

Each solution link opens a readable page with every submitted implementation and variant.

# Problem Statement Difficulty Solutions
1 Two Sum Easy C++
2 Add Two Numbers Medium C++
7 Reverse Integer Medium C++
Java
8 String to Integer atoi Medium C++
9 Palindrome Number Easy C++ — string
C++
Java
11 Container with Most Water Medium C++ — alternative 1
C++ — alternative 2
Java
JavaScript
12 Integer to Roman Medium C++
13 Roman to Integer Easy C++
15 3sum Medium Java — hashmap
Java — hashset
Java
16 3sum Closest Medium C++
17 Letter Combinations of a Phone Number Medium C++
18 4sum Medium Java
19 Remove Nth Node from End of List Medium C++
Java
20 Valid Parentheses Easy Java
21 Merge Two Sorted Lists Easy C++ — alternative 1
C++ — alternative 2
22 Generate Parentheses Medium Java — backtrack
Java
23 Merge K Sorted Lists Hard C++
24 Swap Nodes in Pairs Medium C++
25 Reverse Nodes in K Group Hard Java
26 Remove Duplicates from Sorted Array Easy C++ — alternative 1
C++ — alternative 2
Java
28 Find the Index of the First Occurrence in a String Medium C++
30 Substring with Concatenation of All Words Hard C++
31 Next Permutation Medium Java
32 Longest Valid Parentheses Hard C++
33 Search in Rotated Sorted Array Medium C++
Java
34 Find First and Last Position of Element in Sorted Array Medium Java
35 Search Insert Position Easy C++
Java
36 Valid Sudoku Medium C++
Java
37 Sudoku Solver Hard Java
38 Count and Say Medium C++
Java
39 Combination Sum Medium Java — backtrack preemptive
Java — backtrack
Java
40 Combination Sum II Medium Java
42 Trapping Rain Water Hard C++
47 Permutations II Medium Java
48 Rotate Image Medium C++
Java
49 Group Anagrams Medium C++
50 Powx N Medium Java
53 Maximum Subarray Medium Java
54 Spiral Matrix Medium Java
56 Merge Intervals Medium C++
Java
61 Rotate List Medium Java
62 Unique Paths Medium C++
64 Minimum Path Sum Medium Java — bottomUp
Java — topDown
Java
67 Add Binary Easy C++
68 Text Justification Hard C++
69 Sqrtx Easy C++
70 Climbing Stairs Easy C++
Java — dp memo
Java — dp optimized
Java — dp tab
Java — iterative memo
Java — recursive memo
Java
72 Edit Distance Hard C++
73 Set Matrix Zeroes Medium Java — hashsets of indices
Java
74 Search a 2d Matrix Medium C++
Java
75 Sort Colors Medium C++
Java
76 Minimum Window Substring Hard C++ — alternative 1
C++ — alternative 2
77 Combinations Medium C++
78 Subsets Medium C++
79 Word Search Medium C++
Java — dfs+backtracking
Java
80 Remove Duplicates from Sorted Array II Medium C++
81 Search in Rotated Sorted Array II Medium Java
84 Largest Rectangle in Histogram Hard C++
88 Merge Sorted Array Easy Java
90 Subsets II Medium Java
91 Decode Ways Medium C++
94 Binary Tree Inorder Traversal Easy C++
Java
95 Unique Binary Search Trees II Medium C++
97 Interleaving String Medium C++
98 Validate Binary Search Tree Medium C++
99 Recover Binary Search Tree Medium C++
100 Same Tree Easy C++
102 Binary Tree Level Order Traversal Medium Java
103 Binary Tree Zigzag Level Order Traversal Medium C++
104 Maximum Depth of Binary Tree Easy C++
Java
108 Convert Sorted Array to Binary Search Tree Easy C++
109 Convert Sorted List to Binary Search Tree Medium C++
110 Balanced Binary Tree Easy Java
111 Minimum Depth of Binary Tree Easy C++
112 Path Sum Easy C++
113 Path Sum II Medium C++
116 Populating Next Right Pointers in Each Node Medium C++
118 Pascals Triangle Easy Java
119 Pascals Triangle II Easy Java
120 Triangle Medium Java — bottomUp
Java
121 Best Time to Buy and Sell Stock Easy C++ — alternative 1
C++ — alternative 2
Java — kadane's algorithm
Java — monotonic stack
Java
125 Valid Palindrome Easy C++ — alternative 1
C++ — alternative 2
Java — recursion
126 Word Ladder II Hard C++
128 Longest Consecutive Sequence Medium Java — sorting
Java — union find
Java
131 Palindrome Partitioning Medium C++
134 Gas Station Medium C++ — alternative 1
C++ — alternative 2
135 Candy Hard Java — 2 pass
Java
136 Single Number Easy C++ — alternative 1
C++ — alternative 2
Java
137 Single Number II Medium C++
138 Copy List with Random Pointer Medium Java
139 Word Break Medium C++
141 Linked List Cycle Easy C++
Java
JavaScript
142 Linked List Cycle II Medium C++ — alternative 1
C++ — alternative 2
Java
143 Reorder List Medium C++
144 Binary Tree Preorder Traversal Easy C++
Java
145 Binary Tree Postorder Traversal Easy Java
147 Insertion Sort List Medium C++
148 Sort List Medium Java
149 Max Points on a Line Hard C++
150 Evaluate Reverse Polish Notation Medium C++
151 Reverse Words in a String Medium C++
152 Maximum Product Subarray Medium Java
153 Find Minimum in Rotated Sorted Array Medium Java
154 Find Minimum in Rotated Sorted Array II Hard Java
155 Min Stack Medium Java — AbstractMap.SimpleEntry
Java — pair
Java
160 Intersection of Two Linked Lists Easy C++
Java
162 Find Peak Element Medium Java
165 Compare Version Numbers Medium Java
166 Fraction to Recurring Decimal Medium Java
169 Majority Element Easy Java
173 Binary Search Tree Iterator Medium —
175 Combine Two Tables Easy —
179 Largest Number Medium Java
188 Best Time to Buy and Sell Stock IV Hard C++
189 Rotate Array Medium C++
Java — extra storage
Java — inplace reversal
Java
198 House Robber Medium Java — iterative memo
Java — recursive memo
Java
200 Number of Islands Medium C++ — alternative 1
C++ — alternative 2
Java
203 Remove Linked List Elements Easy C++
206 Reverse Linked List Easy Java
209 Minimum Size Subarray Sum Medium C++
210 Course Schedule II Medium C++
212 Word Search II Hard C++
214 Shortest Palindrome Hard Java
216 Combination Sum III Medium Java
218 The Skyline Problem Hard C++
219 Contains Duplicate II Easy C++ — alternative 1
C++ — alternative 2
JavaScript
221 Maximal Square Medium C++
222 Count Complete Tree Nodes Medium C++
223 Rectangle Area Medium C++
224 Basic Calculator Hard C++
225 Implement Stack Using Queues Easy Java
226 Invert Binary Tree Easy C++
227 Basic Calculator II Medium C++
229 Majority Element II Medium Java — hashmap
Java
230 Kth Smallest Element in a BST Medium C++
231 Power of Two Easy Java — bit manipulation
Java — parity
Java
232 Implement Queue Using Stacks Easy Java
234 Palindrome Linked List Easy C++
Java
235 Lowest Common Ancestor of a Binary Search Tree Easy C++
236 Lowest Common Ancestor of a Binary Tree Medium C++
237 Delete Node in a Linked List Medium C++ — alternative 1
C++ — alternative 2
Java — linear
Java
Java — constant
238 Product of Array Except Self Medium Java
239 Sliding Window Maximum Hard C++
240 Search a 2d Matrix II Medium Java
241 Different Ways to Add Parentheses Medium Java
242 Valid Anagram Easy C++
JavaScript
258 Add Digits Easy C++ — alternative 1
C++ — alternative 2
260 Single Number III Medium Java
263 Ugly Number Easy C++
264 Ugly Number II Medium Java — minheap
Java
273 Integer to English Words Hard Java
278 First Bad Version Easy C++ — alternative 1
C++ — alternative 2
279 Perfect Squares Medium C++
Java
Java — bottomUp
283 Move Zeroes Easy Java
287 Find the Duplicate Number Medium —
290 Word Pattern Easy C++
JavaScript
295 Find Median from Data Stream Hard C++
300 Longest Increasing Subsequence Medium C++
307 Range Sum Query Mutable Medium C++
309 Best Time to Buy and Sell Stock with Cooldown Medium C++
310 Minimum Height Trees Medium C++
312 Burst Balloons Hard C++
319 Bulb Switcher Medium C++
322 Coin Change Medium Java — bottomUp
Java
326 Power of Three Easy C++
Java — log
Java
328 Odd Even Linked List Medium Java
329 Longest Increasing Path in a Matrix Hard Java
330 Patching Array Hard Java
334 Increasing Triplet Subsequence Medium C++
336 Palindrome Pairs Hard C++
338 Counting Bits Easy Java
342 Power of Four Easy C++
Java — math
Java
344 Reverse String Easy C++ — alternative 1
C++ — alternative 2
Java
345 Reverse Vowels of a String Easy C++
349 Intersection of Two Arrays Easy C++
350 Intersection of Two Arrays II Easy Java — 2ptr
Java
363 Max Sum of Rectangle No Larger Than K Hard C++
368 Largest Divisible Subset Medium C++
373 Find K Pairs with Smallest Sums Medium C++
374 Guess Number Higher or Lower Easy C++
377 Combination Sum IV Medium C++
378 Kth Smallest Element in a Sorted Matrix Medium C++
380 Insert Delete Getrandom O1 Medium C++
382 Linked List Random Node Medium C++
383 Ransom Note Easy C++
386 Lexicographical Numbers Medium Java — dfs
Java — string
Java
387 First Unique Character in a String Easy C++
389 Find the Difference Easy C++
392 Is Subsequence Easy C++
393 UTF 8 Validation Medium C++
394 Decode String Medium C++
399 Evaluate Division Medium Java
402 Remove K Digits Medium C++
409 Longest Palindrome Easy Java
416 Partition Equal Subset Sum Medium Java
427 Construct Quad Tree Medium C++
429 N Ary Tree Level Order Traversal Medium C++
432 All Oone Data Structure Hard Java
433 Minimum Genetic Mutation Medium C++
438 Find All Anagrams in a String Medium C++
440 K Th Smallest in Lexicographical Order Hard Java
441 Arranging Coins Easy C++
443 String Compression Medium C++
446 Arithmetic Slices II Subsequence — C++
451 Sort Characters by Frequency Medium C++
452 Minimum Number of Arrows to Burst Balloons Medium C++ — alternative 1
C++ — alternative 2
458 Poor Pigs Hard C++
472 Concatenated Words Hard C++
476 Number Complement Easy C++
Java
485 Max Consecutive Ones Easy Java
486 Predict the Winner Medium C++
494 Target Sum Medium Java — brute force
Java — DP memo2D
Java
502 Ipo Hard C++
Java
509 Fibonacci Number Easy Java — iterative
Java — recursion memoization
Java — recursion
Java
515 Find Largest Value in Each Tree Row Medium Java — bfs
Java — dfs
Java
518 Coin Change II Medium Java
520 Detect Capital Easy C++ — alternative 1
C++ — alternative 2
523 Continuous Subarray Sum Medium C++
525 Contiguous Array Medium C++
532 K Diff Pairs in an Array Medium C++
535 Encode and Decode Tinyurl Medium JavaScript
539 Minimum Time Difference Medium Java
540 Single Element in a Sorted Array Medium C++
Java
543 Diameter of Binary Tree Easy Java
547 Number of Provinces Medium Java
557 Reverse Words in a String III Easy C++
560 Subarray Sum Equals K Medium C++ — alternative 1
C++ — alternative 2
Java
564 Find the Closest Palindrome Hard Java
567 Permutation in String Medium Java — brute force
Java
587 Erect the Fence Hard C++
590 N Ary Tree Postorder Traversal Easy Java
592 Fraction Addition and Subtraction Medium Java
594 Longest Harmonious Subsequence Easy Java — hashmap
Java — sorting
Java
605 Can Place Flowers Easy C++
606 Construct String from Binary Tree Easy C++
609 Find Duplicate File in System Medium C++
JavaScript
611 Valid Triangle Number Medium Java — binary search
Java — brute force
Java
622 Design Circular Queue Medium C++
Java
623 Add One Row to Tree Medium C++
624 Maximum Distance in Arrays Medium Java
628 Maximum Product of Three Numbers Easy Java
632 Smallest Range Covering Elements from K Lists Hard Java
633 Sum of Square Numbers Medium Java
637 Average of Levels in Binary Tree Easy C++
641 Design Circular Deque Medium Java
643 Maximum Average Subarray I Easy C++
JavaScript
645 Set Mismatch Easy C++
648 Replace Words Medium Java
650 2 Keys Keyboard Medium Java — bottomUp
Java
652 Find Duplicate Subtrees Medium C++
653 Two Sum IV Input Is a BST Easy C++
657 Robot Return to Origin Easy Java
658 Find K Closest Elements Medium C++
659 Split Array into Consecutive Subsequences Medium C++
664 Strange Printer Hard C++
Java
670 Maximum Swap Medium Java
684 Redundant Connection Medium Java
689 Maximum Sum of 3 Non Overlapping Subarrays Hard Java
692 Top K Frequent Words Medium C++
701 Insert into a Binary Search Tree Medium C++
703 Kth Largest Element in a Stream Easy Java — bst
Java — sort
Java
704 Binary Search Easy C++
Java
705 Design Hashset Easy C++
712 Minimum ASCII Delete Sum for Two Strings Medium C++
718 Maximum Length of Repeated Subarray Medium C++
719 Find K Th Smallest Pair Distance Hard Java
725 Split Linked List in Parts Medium Java
726 Number of Atoms Hard Java
729 My Calendar I Medium Java
731 My Calendar II Medium Java
732 My Calendar III Hard —
739 Daily Temperatures Medium C++
743 Network Delay Time Medium Java
746 Min Cost Climbing Stairs Easy Java — bottomUp
Java — dfs
Java
762 Prime Number of Set Bits in Binary Representation Easy Java — naive
Java
763 Partition Labels Medium C++
Java
766 Toeplitz Matrix Easy C++
769 Max Chunks to Make Sorted Medium Java — visited nums
Java
771 Jewels and Stones Easy C++ — alternative 1
C++ — alternative 2
773 Sliding Puzzle Hard Java
781 Rabbits in Forest Medium Java
783 Minimum Distance Between BST Nodes Easy C++
787 Cheapest Flights Within K Stops Medium —
790 Domino and Tromino Tiling Medium C++
Java
796 Rotate String Easy Java
797 All Paths from Source to Target Medium C++
802 K Th Smallest Prime Fraction Medium Java — alternative 1
Java — alternative 2
804 Unique Morse Code Words Easy C++
808 Soup Servings Medium Java — dp topDown
Java
814 Binary Tree Pruning Medium C++
826 Most Profit Assigning Work Medium Java
827 Making a Large Island Hard Java
834 Sum of Distances in Tree Hard C++
835 Image Overlap Medium Java
836 Rectangle Overlap Easy Java
837 New 21 Game Medium Java
838 Push Dominoes Medium C++
Java
840 Magic Squares in Grid Medium Java
841 Keys and Rooms Medium C++ — alternative 1
C++ — alternative 2
846 Hand of Straights Medium Java — map
Java
851 Loud and Rich Medium Java — topological_sort
Java
858 Mirror Reflection Medium C++
860 Lemonade Change Easy Java
862 Shortest Subarray with Sum at Least K Hard Java
869 Reordered Power of 2 Medium C++
Java
871 Minimum Number of Refueling Stops Hard C++
873 Length of Longest Fibonacci Subsequence Medium Java — brute force
Java
874 Walking Robot Simulation Medium Java
875 Koko Eating Bananas Medium C++ — alternative 1
C++ — alternative 2
Java
876 Middle of the Linked List Easy C++ — alternative 1
C++ — (2)
C++ — alternative 2
Java
879 Profitable Schemes Hard C++
884 Uncommon Words from Two Sentences Easy Java
885 Spiral Matrix III Medium Java
886 Possible Bipartition Medium C++
890 Find and Replace Pattern Medium C++
893 All Nodes Distance K in Binary Tree Medium C++
895 Maximum Frequency Stack Hard Java
897 Increasing Order Search Tree Easy C++
899 Orderly Queue Hard C++
901 Online Stock Span Medium C++
902 Numbers at Most N Given Digit Set Hard C++
904 Fruit into Baskets Medium C++ — alternative 1
C++ — alternative 2
Java
907 Sum of Subarray Minimums Medium C++
908 Middle of the Linked List Easy C++
909 Snakes and Ladders Medium C++
Java
912 Sort an Array Medium C++
916 Word Subsets Medium C++
Java
918 Maximum Sum Circular Subarray Medium —
921 Minimum Add to Make Parentheses Valid Medium Java
922 Sort Array by Parity II Easy C++
931 Minimum Falling Path Sum Medium Java
936 Stamping the Sequence Hard Java
941 Valid Mountain Array Easy C++
944 Delete Columns to Make Sorted Easy C++
Java
945 Minimum Increment to Make Array Unique Medium Java
947 Most Stones Removed with Same Row or Column Medium C++
Java
948 Bag of Tokens Medium C++
951 Flip Equivalent Binary Trees Medium Java
956 Number of Music Playlists Hard C++
958 Sort Array by Parity II Easy C++
959 Regions Cut by Slashes Medium Java
961 N Repeated Element in Size 2n Array Easy Java
962 Maximum Width Ramp Medium Java
966 Vowel Spellchecker Medium Java — regex
Java — streams
Java
967 Numbers with Same Consecutive Differences Medium C++
973 K Closest Points to Origin Medium C++
974 Subarray Sums Divisible by K Medium C++
Java
976 Largest Perimeter Triangle Easy C++
Java
980 Unique Paths III Hard C++
981 Time Based Key Value Store Medium C++
983 Minimum Cost for Tickets Medium Java — topDown
Java
985 Sum of Even Numbers After Queries Medium C++
987 Vertical Order Traversal of a Binary Tree Hard C++
989 Add to Array Form of Integer Easy C++
990 Satisfiability of Equality Equations Medium C++
994 Rotting Oranges Medium Java
995 Minimum Number of K Consecutive Bit Flips Hard Java
997 Find the Town Judge Easy C++ — alternative 1
C++ — alternative 2
1002 Find Common Characters Easy Java
1004 Max Consecutive Ones III Medium C++
1007 Minimum Domino Rotations for Equal Row Medium Java — simulation
Java
1009 Complement of Base 10 Integer Easy C++
1010 Pairs of Songs with Total Durations Divisible by 60 Medium C++
1011 Capacity to Ship Packages Within D Days Medium —
1014 Best Sightseeing Pair Medium Java
1015 Smallest Integer Divisible by K Medium C++
Java
1022 Sum of Root to Leaf Binary Numbers Easy C++
1026 Maximum Difference Between Node and Ancestor Medium C++
1028 Recover a Tree from Preorder Traversal Hard Java
1038 Binary Search Tree to Greater Sum Tree Medium Java
1041 Robot Bounded in Circle Medium C++
1047 Remove All Adjacent Duplicates in String Easy C++
1051 Height Checker Easy Java
1052 Grumpy Bookstore Owner Medium Java — prefixSum
Java
1061 Lexicographically Smallest Equivalent String Medium Java
1071 Greatest Common Divisor of Strings — C++
1072 Flip Columns for Maximum Number of Equal Rows Medium Java
1079 Letter Tile Possibilities Medium Java
1092 Shortest Common Supersequence Hard Java
1094 Car Pooling Medium C++
1105 Filling Bookcase Shelves Medium Java
1106 Parsing a Boolean Expression Hard Java
1110 Delete Nodes and Return Forest Medium Java
1123 Lowest Common Ancestor of Deepest Leaves Medium Java
1128 Number of Equivalent Domino Pairs Easy Java
1129 Shortest Path with Alternating Colors Medium C++
1137 N Th Tribonacci Number Easy C++
1140 Stone Game II Medium Java
1155 Number of Dice Rolls with Target Sum Medium C++
1162 As Far from Land as Possible — C++
1189 Maximum Number of Balloons Easy Java
1190 Reverse Substrings Between Each Pair of Parentheses Medium Java
1200 Minimum Absolute Difference Easy C++
1202 Smallest String with Swaps Medium Java
1207 Unique Number of Occurrences Easy C++
1208 Get Equal Substrings Within Budget Medium Java
1233 Remove Sub Folders from the Filesystem Medium Java — 2pass trie
Java — sort lexico regex
Java — sort+trie
Java
1235 Maximum Profit in Job Scheduling Hard C++
1239 Maximum Length of a Concatenated String with Unique Characters Medium C++
1248 Count Number of Nice Subarrays Medium Java
1261 Find Elements in a Contaminated Binary Tree Medium Java
1267 Count Servers That Communicate Medium Java
1277 Count Square Submatrices with All Ones Medium Java
1290 Convert Binary Number in a Linked List to Integer Easy Java
1291 Sequential Digits Medium C++
1293 Shortest Path in a Grid with Obstacles Elimination Hard C++
1295 Find Numbers with Even Number of Digits Easy Java
1298 Maximum Candies You Can Get from Boxes Hard Java
1304 Longest Happy String Medium Java — alternative 1
Java — alternative 2
1305 All Elements in Two Binary Search Trees Medium C++
1306 Jump Game III Medium Java
1310 Xor Queries of a Subarray Medium Java
1312 Minimum Insertion Steps to Make a String Palindrome Hard C++
1317 Convert Integer to the Sum of Two No Zero Integers Easy Java
1323 Maximum 69 Number Easy C++
Java — string
Java
1328 Break a Palindrome Medium JavaScript
1329 Sort the Matrix Diagonally Medium C++
C++ — Approach1_1329 sort the matrix diagonally
1331 Rank Transform of an Array Easy Java
1334 Find the City with the Smallest Number of Neighbors at a Threshold Distance Medium Java
1335 Minimum Difficulty of a Job Schedule Hard C++
1338 Reduce Array Size to the Half Medium C++
1344 Angle Between Hands of a Clock Medium Java
1345 Jump Game IV Hard C++
Java — bfs
Java — bidirectional bfs
Java
1346 Check If N and Its Double Exist Easy Java
1352 Product of the Last K Numbers Medium Java
1353 Maximum Number of Events That Can Be Attended Medium Java
1358 Number of Substrings Containing All Three Characters Medium Java — sliding window
Java
1365 How Many Numbers Are Smaller Than the Current Number Easy C++
1367 Linked List in Binary Tree Medium Java
1371 Find the Longest Substring Containing Vowels in Even Counts Medium Java — brute force
Java — sliding window TLE
Java
1380 Lucky Numbers in a Matrix Easy Java
1381 Design a Stack with Increment Operation Medium Java
1382 Balance a Binary Search Tree Medium Java
1390 Four Divisors Medium Java — set
Java
1394 Find Lucky Integer in an Array Easy Java
1395 Count Number of Teams Medium Java
1396 Design Underground System Medium —
1399 Count Largest Group Easy Java
1400 Construct K Palindrome Strings Medium Java — parity counter
Java
1401 Circle and Rectangle Overlapping Medium Java
1404 Number of Steps to Reduce a Number in Binary Representation to One Medium Java
1405 Longest Happy String Medium Java
1408 String Matching in an Array Easy Java
1415 The K Th Lexicographical String of All Happy Strings of Length N Medium Java
1416 Restore the Array Hard C++
1418 Fair Distribution of Cookies Medium C++
1422 Maximum Score After Splitting a String Easy Java — 1 pass
Java — 1 ptr
Java — 2 pass
Java
1432 Max Difference You Can Get from Changing an Integer Medium Java
1438 Longest Continuous Subarray with Absolute Diff Less Than or Equal to Limit Medium Java
1443 Minimum Time to Collect All Apples in a Tree Medium C++
1448 Count Good Nodes in Binary Tree Medium C++
1455 Check If a Word Occurs as a Prefix of Any Word in a Sentence Easy Java
1457 Pseudo Palindromic Paths in a Binary Tree Medium C++
1460 Make Two Arrays Equal by Reversing Subarrays Easy Java — map
Java — sort
Java
1462 Course Schedule IV Medium Java
1463 Cherry Pickup II Hard C++
1464 Maximum Product of Two Elements in an Array Easy Java
1475 Final Prices with a Special Discount in a Shop Easy Java
1477 Find Two Non Overlapping Sub Arrays Each with Target Sum Medium Java
1482 Minimum Number of Days to Make M Bouquets Medium C++
Java
1488 Avoid Flood in the City Medium Java — brute force
Java
1493 Longest Subarray of 1s After Deleting One Element Medium Java
1497 Check If Array Pairs Are Divisible by K Medium Java
1498 Number of Subsequences That Satisfy the Given Sum Condition Medium Java — binarySearch multiple
Java
1504 Count Submatrices with All Ones Medium Java
1508 Range Sum of Sorted Subarray Sums Medium Java
1509 Minimum Difference Between Largest and Smallest Value in Three Moves Medium Java
1510 Stone Game IV Hard C++
1514 Path with Maximum Probability Medium C++
Java
1518 Water Bottles Easy Java
1519 Number of Nodes in the Sub Tree with the Same Label Medium C++
1523 Count Odd Numbers in an Interval Range Easy —
1524 Number of Sub Arrays with Odd Sum Medium Java
1530 Number of Good Leaf Nodes Pairs Medium Java
1531 String Compression II Hard C++
1534 Count Good Triplets Easy Java
1544 Make the String Great Easy C++
1545 Find Kth Bit in Nth Binary String Medium Java
1550 Three Consecutive Odds Easy Java
1552 Magnetic Force Between Two Balls Medium Java
1568 Minimum Number of Days to Disconnect Island Hard Java
1574 Shortest Subarray to Be Removed to Make Array Sorted Medium Java
1578 Minimum Time to Make Rope Colorful Medium C++
JavaScript
1579 Remove Max Number of Edges to Keep Graph Fully Traversable Hard Java
1584 Min Cost to Connect All Points Medium C++
1586 Longest Subarray of 1s After Deleting One Element Medium C++
1590 Make Sum Divisible by P Medium Java
1593 Split a String into the Max Number of Unique Substrings Medium Java — backtrack prune
Java — backtrack
Java
1598 Crawler Log Folder Easy Java
1605 Minimum Number of Days to Make M Bouquets Medium Java — alternative 1
Java — alternative 2
1608 Special Array with X Elements Greater Than or Equal X Easy Java — nlogn
Java
1627 Last Moment Before All Ants Fall Out of a Plank Medium C++
1636 Sort Array by Increasing Frequency Easy Java
1639 Number of Ways to Form a Target String Given a Dictionary Hard C++
Java
1652 Defuse the Bomb Easy Java
1653 Minimum Deletions to Make String Balanced Medium Java — dp
Java — prefix_suffix
Java
1657 Determine If Two Strings Are Close Medium C++
1658 Minimum Operations to Reduce X to Zero Medium Java
1662 Check If Two String Arrays Are Equivalent Easy C++
1671 Minimum Number of Removals to Make Mountain Array Hard Java
1672 Richest Customer Wealth Easy C++
1680 Concatenation of Consecutive Binary Numbers Medium C++
1684 Count the Number of Consistent Strings Easy Java
1701 Average Waiting Time Medium Java
1704 Determine If String Halves Are Alike Easy C++
1706 Where Will the Ball Fall Medium C++ — alternative 1
C++ — alternative 2
1711 Find Valid Matrix Given Row and Column Sums Medium Java
1716 Calculate Money in Leetcode Bank Easy Java
1717 Maximum Score from Removing Substrings Medium Java
1718 Construct the Lexicographically Largest Valid Sequence Medium Java
1723 Maximum Number of Achievable Transfer Requests Hard C++
1726 Tuple with Same Product Medium Java
1732 Find the Highest Altitude Easy Java
1733 Minimum Number of People to Teach Medium Java
1749 Maximum Absolute Sum of Any Subarray Medium Java
1752 Check If Array Is Sorted and Rotated Easy Java
1760 Minimum Limit of Balls in a Bag Medium Java
1765 Map of Highest Peak Medium Java — bfs floodFill
Java
1769 Minimum Number of Operations to Move All Balls to Each Box Medium Java
1770 Minimum Deletions to Make Character Frequencies Unique Medium C++ — alternative 1
C++ — alternative 2
1776 Minimum Operations to Reduce X to Zero Medium C++
Java
1780 Check If Number Is a Sum of Powers of Three Medium Java — greedy
Java
1790 Check If One String Swap Can Make Strings Equal Easy Java
1791 Find Center of Star Graph Easy Java — O(n)
Java
1792 Maximum Average Pass Ratio Medium Java
1800 Maximum Ascending Subarray Sum Easy Java
1807 Evaluate the Bracket Pairs of a String Medium Java
1813 Sentence Similarity III Medium Java
1823 Find the Winner of the Circular Game Medium Java — simulate
Java
1829 Maximum Xor for Each Query Medium Java
1832 Check If the Sentence Is Pangram Easy C++
1833 Maximum Ice Cream Bars Medium C++
Java
1834 Single Threaded CPU Medium C++
1838 Frequency of the Most Frequent Element Medium Java
1840 Maximum Building Height Hard Java
1846 Maximum Element After Decreasing and Rearranging Medium Java
1861 Rotating the Box Medium Java
1863 Sum of All Subset Xor Totals Easy Java
1865 Finding Pairs with a Certain Sum Medium Java
1894 Find the Student That Will Replace the Chalk Medium Java — prefix_sum+bin_search
Java — prefix_sum+iterative
Java
1905 Count Sub Islands Medium Java
1920 Build Array from Permutation Easy Java
1922 Count Good Numbers Medium Java
1926 Nearest Exit from Entrance in Maze Medium C++
1930 Unique Length 3 Palindromic Subsequences Medium Java
1935 Maximum Number of Words You Can Type Easy Java
1937 Maximum Number of Points with Cost Medium Java
1942 The Number of the Smallest Unoccupied Chair Medium Java
1945 Sum of Digits of String After Convert Easy Java
1957 Delete Characters to Make Fancy String Easy Java
1962 Remove Stones to Minimize the Total Medium C++
1963 Minimum Number of Swaps to Make the String Balanced Medium Java
1967 Number of Strings That Appear as Substrings in Word Easy Java
1971 Find If Path Exists in Graph Easy C++
1975 Maximum Matrix Sum Medium Java
1976 Number of Ways to Arrive at Destination Medium Java
1980 Find Unique Binary String Medium Java
1996 The Number of Weak Characters in the Game Medium C++
2000 Minimum Speed to Arrive on Time Medium C++
2007 Find Original Array from Doubled Array Medium C++
2011 Final Value of Variable After Performing Operations Easy Java
2016 Maximum Difference Between Increasing Elements Easy Java
2017 Grid Game Medium Java
2022 Convert 1d Array into 2d Array Easy Java
2028 Find Missing Observations Medium Java
2029 Stone Game Ix Medium Java
2033 Minimum Operations to Make a Uni Value Grid Medium Java
2037 Minimum Number of Moves to Seat Everyone Easy Java
2043 Simple Bank System Medium Java
2044 Count Number of Maximum Bitwise or Subsets Medium Java — bit manipulation
Java — recursion memo
Java — recursion
Java
2045 Second Minimum Time to Reach Destination Hard Java
2048 Next Greater Numerically Balanced Number Medium Java
2053 Kth Distinct String in an Array Easy Java
2054 Two Best Non Overlapping Events Medium Java
2058 Find the Minimum and Maximum Number of Nodes Between Critical Points Medium Java
2064 Minimized Maximum of Products Distributed to Any Store Medium Java
2070 Most Beautiful Item for Each Query Medium Java
2091 Removing Minimum and Maximum from Array Medium Java
2094 Finding 3 Digit Even Numbers Easy Java
2095 Delete the Middle Node of a Linked List Medium C++
Java
2096 Step by Step Directions from a Binary Tree Node to Another Medium Java
2097 Valid Arrangement of Pairs Hard Java
2099 Find Subsequence of Length K with the Largest Sum Easy Java — 2 heaps
Java — sort twice
Java
2101 Last Day Where You Can Still Cross Hard C++
Java
2106 Maximum Fruits Harvested After at Most K Steps Hard Java
2109 Adding Spaces to a String Medium Java — stringBuilder
Java
2115 Find All Possible Recipes from Given Supplies Medium Java
2116 Check If a Parentheses String Can Be Valid Medium Java
2125 Number of Laser Beams in a Bank Medium Java
2126 Destroying Asteroids Medium Java
2130 Maximum Twin Sum of a Linked List Medium Java
2131 Longest Palindrome by Concatenating Two Letter Words Medium C++
Java — hashmap
Java
2134 Minimum Swaps to Group All 1s Together II Medium C++
Java
2136 Earliest Possible Day of Full Bloom — C++
2138 Divide a String into Groups of Size K Easy Java
2140 Solving Questions with Brainpower Medium Java — DP top down
Java
2144 Minimum Cost of Buying Candies with Discount Easy Java
2145 Count the Hidden Sequences Medium Java
2149 Rearrange Array Elements by Sign Medium Java
2161 Partition Array According to Given Pivot Medium Java — store in array
Java
2176 Count Equal and Divisible Pairs in an Array Easy Java — naive
Java
Java — hashmap
2179 Count Good Triplets in an Array Hard Java
2181 Merge Nodes in Between Zeros Medium Java
2182 Construct String with Repeat Limit Medium Java
2185 Counting Words with a Given Prefix Easy Java — 1 liner stream lambda
Java
2191 Sort the Jumbled Numbers Medium Java
2192 All Ancestors of a Node in a Directed Acyclic Graph Medium Java
2196 Create Binary Tree from Descriptions Medium Java
2200 Find All K Distant Indices in an Array Easy Java
2206 Divide Array into Equal Pairs Easy Java — hashset
Java
2210 Count Hills and Valleys in an Array Easy Java
2211 Count Collisions on a Road Medium Java
2220 Minimum Bit Flips to Convert Number Easy Java — bit masking
Java — bit shifting
Java
2221 Find Triangular Sum of an Array Medium Java — simulation inPlace
Java
2225 Find Players with Zero or One Losses Medium C++
2226 Maximum Candies Allocated to K Children Medium Java
2244 Minimum Rounds to Complete All Tasks Medium C++
2246 Longest Path with Different Adjacent Characters Hard C++
2256 Minimum Average Difference Medium C++
2257 Count Unguarded Cells in the Grid Medium Java
2259 Remove Digit from Number to Maximize Result Easy C++
Java
2260 Minimum Consecutive Cards to Pick Up Medium C++
Java
2264 Largest 3 Same Digit Number in String Easy Java
Java — naive
2265 Count Nodes Equal to Average of Subtree Medium Java
2270 Number of Ways to Split Array Medium Java — prefixSum_O_1_space
Java — prefixSum O_n_space
Java
2273 Find Resultant Array After Removing Anagrams Easy Java
2275 Largest Combination with Bitwise and Greater Than Zero Medium Java
2279 Maximum Bags with Full Capacity of Rocks Medium C++
2285 Maximum Total Importance of Roads Medium Java
2290 Minimum Obstacle Removal to Reach Corner Hard Java
2294 Partition Array Such That Maximum Difference Is K Medium Java
2302 Count Subarrays with Score Less Than K Hard Java
2306 Naming a Company Hard —
2311 Longest Binary Subsequence Less Than or Equal to K Medium Java
2326 Spiral Matrix IV Medium Java
2327 Number of People Aware of a Secret Medium Java
2336 Smallest Number in Infinite Set Medium C++
2337 Remove Digit from Number to Maximize Result Easy Java — alternative 1
Java — alternative 2
2338 Count the Number of Ideal Arrays Hard Java
2342 Max Sum of a Pair with Equal Sum of Digits Medium Java
2347 Count Nodes Equal to Average of Subtree Medium C++
2348 Number of Zero Filled Subarrays Medium C++
Java
2349 Design a Number Container System Medium Java — 2 maps 1 of meanHeaps with lazy update
Java — 2 maps 1 of treesets
Java
2353 Design a Food Rating System Medium Java
2359 Find Closest Node to Given Two Nodes Medium C++
Java
2360 Substring with Largest Variance Hard —
2364 Count Number of Bad Pairs Medium Java
2373 Largest Local Values in a Matrix Easy Java
2379 Minimum Recolors to Get K Consecutive Black Blocks Easy Java
2381 Shifting Letters II Medium Java
2389 Longest Subsequence with Limited Sum Easy —
2392 Build a Matrix with Conditions Hard Java — topological sort
Java
2401 Longest Nice Subarray Medium Java — optimized sliding window
Java
2402 Meeting Rooms III Hard Java
2406 Divide Intervals into Minimum Number of Groups Medium Java — line sweep ordered
Java
2410 Maximum Matching of Players with Trainers Medium Java
2415 Reverse Odd Levels of Binary Tree Medium Java
2416 Sum of Prefix Scores of Strings Hard Java
2418 Sort the People Easy Java
2419 Longest Subarray with Maximum Bitwise And Medium Java
2421 Number of Good Paths Hard —
2425 Bitwise Xor of All Pairings Medium Java
2429 Minimize Xor Medium Java
2434 Using a Robot to Print the Lexicographically Smallest String Medium Java
2438 Range Product Queries of Powers Medium Java — brute force
Java — prefix 2D
Java
2444 Count Subarrays with Fixed Bounds Hard Java
2456 Most Popular Video Creator Medium C++
Java
2458 Height of Binary Tree After Subtree Removal Queries Hard Java — 2pass traversal
Java
2460 Apply Operations to an Array Easy C++
Java
2461 Maximum Sum of Distinct Subarrays with Length K Medium C++
Java
2462 Total Cost to Hire K Workers Medium C++
2463 Minimum Total Distance Traveled Hard Java
2466 Count Ways to Build Good Strings Medium Java
2467 Most Profitable Path in a Tree Medium Java
2469 Convert the Temperature Easy C++
2470 Number of Subarrays with Lcm Equal to K Medium C++
2471 Minimum Number of Operations to Sort a Binary Tree by Level Medium C++
Java
2475 Number of Unequal Triplets in Array Easy C++
2476 Closest Nodes Queries in a Binary Search Tree Medium C++
2485 Find the Pivot Integer Easy C++
2486 Append Characters to String to Make Subsequence Medium Java
2490 Circular Sentence Easy Java
2491 Divide Players into Teams of Equal Skill Medium Java
2501 Longest Square Streak in an Array Medium Java
2503 Maximum Number of Points from Grid Queries Hard Java
2516 Take K of Each Character from Left and Right Medium Java
2519 Find the Original Array of Prefix Xor Medium C++
2520 Count the Digits That Divide a Number Easy —
2521 Distinct Prime Factors of Product of Array Medium C++
2522 Partition String into Substrings with Values at Most K Medium C++
2523 Closest Prime Numbers in Range Medium Java
2529 Maximum Count of Positive Integer and Negative Integer Easy Java — binary search
Java — brute force
Java
2530 Maximal Score After Applying K Operations Medium Java — max heap
Java
2536 Increment Submatrices by One Medium —
2537 Count the Number of Good Subarrays Medium Java
2544 Alternating Digit Sum Easy C++
2545 Sort the Students by Their Kth Score Medium C++
2546 Apply Bitwise Operations to Make Strings Equal Medium C++
2551 Put Marbles in Bags Hard Java
2554 Maximum Number of Integers to Choose from a Range I Medium Java — sort
Java
2558 Take Gifts from the Richest Pile Easy C++
Java
2559 Count Vowel Strings in Ranges Medium C++
Java
2560 House Robber IV Medium Java
2563 Count the Number of Fair Pairs Medium Java — binary search basic
Java
2566 Maximum Difference by Remapping a Digit Easy Java
2570 Merge Two 2d Arrays by Summing Values Easy Java
2574 Left and Right Sum Differences Easy Java
2577 Minimum Time to Visit a Cell in a Grid Hard Java
2579 Count Total Number of Colored Cells Medium Java — agp series
Java
2582 Pass the Pillow Easy Java
2583 Kth Largest Sum in a Binary Tree Medium Java — bfs+maxheap
Java — bfs+minheap
Java
2593 Find Score of an Array After Marking All Elements Medium Java
2594 Minimum Time to Repair Cars Medium Java — binary search
Java
2598 Smallest Missing Non Negative Integer After Operations Medium Java
2601 Prime Subtraction Operation Medium Java
2616 Minimize the Maximum Difference of Pairs Medium Java
2641 Cousins in Binary Tree II Medium Java — 1pass BFS
Java — 2pass BFS+DFS
Java
2657 Find the Prefix Common Array of Two Arrays Medium Java
2658 Maximum Number of Fish in a Grid Medium Java
2661 First Completely Painted Row or Column Medium Java
2678 Number of Senior Citizens Easy Java — string
Java
2681 Put Marbles in Bags Hard C++
2684 Maximum Number of Moves in a Grid Medium Java
2685 Count the Number of Complete Components Medium Java
2696 Minimum String Length After Removing Substrings Easy Java — stack
Java
2698 Find the Punishment Number of an Integer Medium Java — cheating
Java
2699 Modify Graph Edge Weights Hard Java
2707 Extra Characters in a String Medium Java
2749 Minimum Operations to Make the Integer Zero Medium Java
2751 Robot Collisions Hard Java
2762 Continuous Subarrays Medium Java
2770 Maximum Number of Jumps to Reach the Last Index Medium Java
2779 Maximum Beauty of an Array After Applying Operation Medium Java
2780 Minimum Index of a Valid Split Medium Java
2785 Sort Vowels in a String Medium Java
2787 Ways to Express an Integer as Sum of Powers Medium Java — dp bottomUp
Java — dp topDown
Java
2799 Count Complete Subarrays in an Array Medium Java
2807 Insert Greatest Common Divisors in Linked List Medium Java
2818 Apply Operations to Maximize Score Hard Java
2825 Make String a Subsequence Using Cyclic Increments Medium Java
2843 Count Symmetric Integers Easy Java — digit extraction — alternative 1
Java — string
Java
Java — digit extraction — alternative 2
2845 Count of Interesting Subarrays Medium Java
2873 Maximum Value of an Ordered Triplet I Easy Java
2874 Maximum Value of an Ordered Triplet II Medium Java — prefixSum
Java
2894 Divisible and Non Divisible Sums Difference Easy Java — math
Java — simulation
Java
2900 Longest Unequal Adjacent Groups Subsequence I Easy Java
2904 Shortest and Lexicographically Smallest Beautiful String Medium Java — sliding window substring
Java
2914 Minimum Number of Changes to Make Binary String Beautiful Medium Java
2918 Minimum Equal Sum of Two Arrays After Replacing Zeros Medium Java
2924 Find Champion II Medium Java
2929 Distribute Candies Among Children II Medium Java — enumeration
Java — math
Java
2938 Separate Black and White Balls Medium Java — 2 ptrs
Java
2940 Find Building Where Alice and Bob Can Meet Hard Java
2942 Find Words Containing Character Easy Java
2948 Make Lexicographically Smallest Array by Swapping Elements Medium Java
2962 Count Subarrays Where Max Element Appears at Least K Times Medium Java
2965 Find Missing and Repeated Values Easy Java — frequency
Java
2966 Divide Array into Arrays with Max Difference Medium Java
2976 Minimum Cost to Convert String I Medium Java — djikstra
Java
2981 Find Longest Special Substring That Occurs Thrice I Medium Java
3000 Maximum Area of Longest Diagonal Rectangle Easy Java
3005 Count Elements with Maximum Frequency Easy Java
3011 Find If Array Can Be Sorted Medium Java
3014 Minimum Number of Pushes to Type Word I Easy Java — simulation
Java
3016 Minimum Number of Pushes to Type Word II Medium Java
3020 Find the Maximum Number of Elements in Subset Medium Java
3024 Type of Triangle Easy Java
3025 Find the Number of Ways to Place People I Medium Java — simulation
Java
3042 Count Prefix and Suffix Pairs I Easy Java
3043 Find the Length of the Longest Common Prefix Medium Java
3066 Minimum Operations to Exceed Threshold Value II Medium Java
3085 Minimum Deletions to Make String K Special Medium Java
3093 Longest Common Suffix Queries Hard Java
3097 Shortest Subarray with or at Least K II Medium Java
3100 Water Bottles II Medium Java
3105 Longest Strictly Increasing or Strictly Decreasing Subarray Easy Java
3108 Minimum Cost Walk in Weighted Graph Hard Java
3110 Score of a String Easy Java
3121 Count the Number of Special Characters II Medium Java
3133 Minimum Array End Medium —
3151 Special Array I Easy Java
3152 Special Array II Medium Java — alternative 1
Java — alternative 2
3160 Find the Number of Distinct Colors Among the Balls Medium Java
3163 String Compression III Medium Java
3169 Count Days Without Meetings Medium Java — line sweep
Java
3170 Lexicographically Minimum String After Removing Stars Medium Java — heap
Java
3174 Clear Digits Easy Java
3190 Find Minimum Operations to Make All Elements Divisible by Three Easy Java
3191 Minimum Operations to Make Binary Array Elements Equal to One I Medium Java
3195 Find the Minimum Area to Cover All Ones I Medium Java — simulation
Java
3203 Find Minimum Diameter After Merging Two Trees Hard Java
3208 Alternating Groups II Medium Java
3217 Delete Nodes from Linked List Present in Array Medium Java
3223 Minimum Length of String After Operations Medium Java
3227 Vowels Game in a String Medium Java — stream api
Java
3243 Shortest Distance After Road Addition Queries I Medium Java
3254 Find the Power of K Size Subarrays I Medium Java
3264 Final Array State After K Multiplication Operations I Easy Java
3286 Find a Safe Walk Through a Grid Medium Java
3289 The Two Sneaky Numbers of Digitville Easy Java — memo
Java — sorting
Java
3300 Minimum Element After Replacement with Digit Sum Easy Java
3304 Find the K Th Character in String Game I Easy Java — simulation
Java
3306 Count of Substrings Containing Every Vowel and K Consonants II Medium Java
3330 Find the Original Typed String I Easy Java
3335 Total Characters in String After Transformations I Medium Java — circular array
Java — simulation
Java
3337 Total Characters in String After Transformations II Hard Java
3341 Find Minimum Time to Reach Last Room I Medium Java
3342 Find Minimum Time to Reach Last Room II Medium Java
3343 Count Number of Balanced Permutations Hard Java
3350 Adjacent Increasing Subarrays Detection II Medium Java
3354 Make Array Elements Equal to Zero Easy Java
3355 Zero Array Transformation I Medium Java
3356 Zero Array Transformation II Medium Java
3362 Zero Array Transformation III Medium Java
3372 Maximize the Number of Target Nodes After Connecting Trees I Medium Java — bfs
Java — dfs
Java
3373 Maximize the Number of Target Nodes After Connecting Trees II Hard Java
3375 Minimum Operations to Make Array Values Equal to K Easy Java — sorting
Java
3392 Count Subarrays of Length Three with a Condition Easy Java
3394 Check If Grid Can Be Cut into Sections Medium Java
3396 Minimum Number of Operations to Make Elements in Array Distinct Easy Java — hashmap
Java
3397 Maximum Number of Distinct Elements After Operations Medium Java — treeset
Java
3403 Find the Lexicographically Largest String from the Box I Medium Java
3408 Design Task Manager Medium Java
3423 Maximum Difference Between Adjacent Elements in a Circular Array Easy Java
3433 Count Mentions Per User Medium Java — simulation
Java
3439 Reschedule Meetings for Maximum Free Time I Medium Java
3440 Reschedule Meetings for Maximum Free Time II Medium Java
3442 Maximum Difference Between Even and Odd Frequency I Easy Java
3443 Maximum Manhattan Distance After K Changes Medium Java
3445 Maximum Difference Between Even and Odd Frequency II Hard Java
3461 Check If Digits Are Equal in String After Operations I Easy Java
3477 Fruits into Baskets II Easy Java
3483 Unique 3 Digit Even Numbers Easy Java
3484 Design Spreadsheet Medium Java
3487 Maximum Unique Subarray Sum After Deletion Easy Java
3494 Find the Minimum Amount of Time to Brew Potions Medium Java
3498 Reverse Degree of a String Easy Java
3508 Implement Router Medium Java — myDesign TLE
Java
3512 Minimum Operations to Make Array Sum Divisible by K Easy Java
3516 Find Closest Person Easy Java
3536 Maximum Product of Two Digits Easy Java
3541 Find Most Frequent Vowel and Consonant Easy Java
3542 Minimum Operations to Convert All Elements to Zero Medium Java
3558 Number of Ways to Assign Edge Weights I Medium Java
3583 Count Special Triplets Medium Java
3606 Coupon Code Validator Easy Java
3612 Process String with Special Operations I Medium Java
3614 Process String with Special Operations II Hard Java
3620 Network Recovery Pathways Hard Java
3622 Check Divisibility by Digit Sum and Product Easy Java
3633 Earliest Finish Time for Land and Water Rides I Easy Java
3635 Earliest Finish Time for Land and Water Rides II Medium Java
3689 Maximum Total Subarray Value I Medium Java
3691 Maximum Total Subarray Value II Hard Java
3699 Number of Zigzag Arrays I Hard Java
3737 Count Subarrays with Majority Element I Medium Java — prefix sum
Java — segment tree naive
Java — segment tree — alternative 1
Java
Java — segment tree — alternative 2
3751 Total Waviness of Numbers in Range I Medium Java — naive
Java
3838 Weighted Word Mapping Easy Java
3871 Count Commas in Range II Medium Java — direct
Java
3875 Construct Uniform Parity Array I Easy Java
3876 Construct Uniform Parity Array II Medium Java
3904 Smallest Stable Index II Medium Java
4034 Minimum Bishop Moves to Reach Target Medium Java
4036 Lexicographically Largest String After Pair Transformations Medium Java
4048 Count Values with Equally Spaced Occurrences I Easy Java
4049 Count Values with Equally Spaced Occurrences II Medium Java
4050 Minimum Days to Score Exactly N Points Medium Java

About

Documenting my LeetCode journey one problem at a time. Feel free to use this repository's public template

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages