Rust LeetCode Typing Practice
197 LeetCode solutions in Rust. Pick one to type it and see your WPM and accuracy.
- 01 Matrix · 28 lines
- 3Sum · 37 lines
- 3Sum Closest · 29 lines
- 4Sum · 72 lines
- Adding Spaces to a String · 22 lines
- Apply Discount to Prices · 29 lines
- Arithmetic Subarrays · 41 lines
- Array of Doubled Pairs · 45 lines
- Asteroid Collision · 28 lines
- Average Salary Excluding the Minimum and Maximum Salary · 12 lines
- Backspace String Compare · 35 lines
- Beautiful Arrangement II · 21 lines
- Binary Search · 18 lines
- Bulls and Cows · 19 lines
- Card Flipping Game · 17 lines
- Cat and Mouse II · 86 lines
- Champagne Tower · 15 lines
- Check if Every Row and Column Contains All Numbers · 17 lines
- Check If N and Its Double Exist · 21 lines
- Check if There Is a Valid Parentheses String Path · 39 lines
- Check If Two String Arrays are Equivalent · 5 lines
- Check If Word Is Valid After Substitutions · 27 lines
- Circular Permutation in Binary Representation · 16 lines
- Clumsy Factorial · 26 lines
- Combination Sum IV · 16 lines
- Consecutive Characters · 12 lines
- Construct Target Array With Multiple Sums · 33 lines
- Construct the Lexicographically Largest Valid Sequence · 53 lines
- Convert Binary Number in a Linked List to Integer · 15 lines
- Count Items Matching a Rule · 28 lines
- Count Number of Nice Subarrays · 28 lines
- Count Number of Special Subsequences · 11 lines
- Count of Smaller Numbers After Self · 49 lines
- Count Servers that Communicate · 30 lines
- Count Subarrays With Score Less Than K · 19 lines
- Count Submatrices With All Ones · 37 lines
- Count Vowels Permutation · 27 lines
- Cyclically Rotating a Grid · 55 lines
- Decode String · 23 lines
- Decode Ways · 19 lines
- Decrypt String from Alphabet to Integer Mapping · 24 lines
- Distribute Candies · 9 lines
- Divide Array in Sets of K Consecutive Numbers · 35 lines
- Divide Two Integers · 28 lines
- Domino and Tromino Tiling · 42 lines
- Elimination Game · 17 lines
- Equal Sum Arrays With Minimum Number of Operations · 37 lines
- Evaluate Boolean Binary Tree · 16 lines
- Execution of All Suffix Instructions Staying in a Grid · 60 lines
- Fibonacci Number · 12 lines
- Final Prices With a Special Discount in a Shop · 15 lines
- Find And Replace in String · 52 lines
- Find and Replace Pattern · 45 lines
- Find Good Days to Rob the Bank · 29 lines
- Find K Pairs with Smallest Sums · 23 lines
- Find Kth Bit in Nth Binary String · 27 lines
- Find Largest Value in Each Tree Row · 30 lines
- Find Lucky Integer in an Array · 17 lines
- Find the Closest Palindrome · 31 lines
- Find the Distance Value Between Two Arrays · 8 lines
- Find the Kth Smallest Sum of a Matrix With Sorted Rows · 27 lines
- Find the Longest Substring Containing Vowels in Even Counts · 33 lines
- Find the Minimum Number of Fibonacci Numbers Whose Sum Is K · 28 lines
- Find the Shortest Superstring · 59 lines
- Find Words That Can Be Formed by Characters · 22 lines
- Flood Fill · 28 lines
- Frog Jump · 33 lines
- Get Watched Videos by Your Friends · 49 lines
- Global and Local Inversions · 15 lines
- Greatest Common Divisor of Strings · 15 lines
- Grid Illumination · 68 lines
- Hand of Straights · 23 lines
- How Many Numbers Are Smaller Than the Current Number · 8 lines
- Intersection of Multiple Arrays · 20 lines
- Intersection of Two Arrays II · 17 lines
- Is Subsequence · 12 lines
- Jump Game V · 72 lines
- Largest Divisible Subset · 39 lines
- Largest Merge Of Two Strings · 19 lines
- Largest Multiple of Three · 69 lines
- Largest Rectangle in Histogram · 39 lines
- Largest Substring Between Two Equal Characters · 23 lines
- Lemonade Change · 14 lines
- Length of Last Word · 9 lines
- Letter Combinations of a Phone Number · 30 lines
- Longest Absolute File Path · 38 lines
- Longest Arithmetic Subsequence of Given Difference · 26 lines
- Longest Increasing Path in a Matrix · 31 lines
- Longest Increasing Subsequence · 18 lines
- Longest Repeating Character Replacement · 20 lines
- Longest Word in Dictionary · 30 lines
- Make The String Great · 10 lines
- Matrix Block Sum · 27 lines
- Matrix Cells in Distance Order · 28 lines
- Max Difference You Can Get From Changing an Integer · 53 lines
- Maximal Square · 25 lines
- Maximum Alternating Subsequence Sum · 16 lines
- Maximum Ascending Subarray Sum · 14 lines
- Maximum Erasure Value · 25 lines
- Maximum Height by Stacking Cuboids · 42 lines
- Maximum Ice Cream Bars · 20 lines
- Maximum Length of Pair Chain · 18 lines
- Maximum Number of Balloons · 17 lines
- Maximum Number of Coins You Can Get · 7 lines
- Maximum Number of Groups Entering a Competition · 20 lines
- Maximum Number of Pairs in Array · 23 lines
- Maximum Number of Words You Can Type · 20 lines
- Maximum Product of Word Lengths · 22 lines
- Maximum Score of a Node Sequence · 76 lines
- Maximum White Tiles Covered by a Carpet · 49 lines
- Minimum Cost to Connect Two Groups of Points · 33 lines
- Minimum Cost to Cut a Stick · 25 lines
- Minimum Cost to Move Chips to The Same Position · 6 lines
- Minimum Cost to Reach Destination in Time · 53 lines
- Minimum Cost Tree From Leaf Values · 26 lines
- Minimum Index Sum of Two Lists · 28 lines
- Minimum Initial Energy to Finish Tasks · 19 lines
- Minimum Number of Days to Make m Bouquets · 59 lines
- Minimum Number of Increments on Subarrays to Form a Target Array · 13 lines
- Minimum Number of Steps to Make Two Strings Anagram II · 16 lines
- Minimum Numbers of Function Calls to Make Target Array · 22 lines
- Minimum Operations to Reduce X to Zero · 25 lines
- Minimum Swaps to Make Strings Equal · 24 lines
- Minimum Time to Complete Trips · 22 lines
- Minimum Weighted Subgraph With the Required Paths · 55 lines
- Minimum Window Substring · 52 lines
- Next Greater Numerically Balanced Number · 22 lines
- Number Complement · 9 lines
- Number of Dice Rolls With Target Sum · 21 lines
- Number of Distinct Roll Sequences · 59 lines
- Number of Equivalent Domino Pairs · 12 lines
- Number of Flowers in Full Bloom · 18 lines
- Number of Increasing Paths in a Grid · 47 lines
- Number of Restricted Paths From First to Last Node · 78 lines
- Number of Substrings With Only 1s · 17 lines
- Number of Visible People in a Queue · 17 lines
- Number of Ways to Arrive at Destination · 56 lines
- Number of Ways to Divide a Long Corridor · 27 lines
- Number of Ways to Split Array · 18 lines
- Odd Even Linked List · 24 lines
- Palindrome Number · 5 lines
- Partition Array for Maximum Sum · 21 lines
- Partition Array Into Two Arrays to Minimize Sum Difference · 47 lines
- Partition Labels · 22 lines
- Partition List · 27 lines
- Patching Array · 19 lines
- Possible Bipartition · 59 lines
- Predict the Winner · 20 lines
- Prime Arrangements · 12 lines
- Race Car · 47 lines
- Reconstruct Original Digits from English · 49 lines
- Rectangle Overlap · 10 lines
- Redundant Connection · 34 lines
- Relative Sort Array · 24 lines
- Remove Max Number of Edges to Keep Graph Fully Traversable · 69 lines
- Repeated Substring Pattern · 23 lines
- Restore The Array · 25 lines
- Restore the Array From Adjacent Pairs · 46 lines
- Reveal Cards In Increasing Order · 16 lines
- Reverse Integer · 15 lines
- Reverse Nodes in Even Length Groups · 36 lines
- Reverse Substrings Between Each Pair of Parentheses · 25 lines
- Rotting Oranges · 51 lines
- Scramble String · 28 lines
- Sign of the Product of an Array · 5 lines
- Single Number III · 15 lines
- Smallest Subtree with all the Deepest Nodes · 29 lines
- Sort Array By Parity · 17 lines
- Sort Items by Groups Respecting Dependencies · 97 lines
- Sort the Matrix Diagonally · 37 lines
- Special Positions in a Binary Matrix · 27 lines
- Split a String Into the Max Number of Unique Substrings · 34 lines
- Squares of a Sorted Array · 43 lines
- Stone Game II · 53 lines
- Strong Password Checker II · 21 lines
- Substring With Largest Variance · 48 lines
- Sum of Beauty in the Array · 28 lines
- Sum of Total Strength of Wizards · 58 lines
- Super Washing Machines · 21 lines
- Swap Nodes in Pairs · 36 lines
- Tag Validator · 108 lines
- Target Sum · 30 lines
- Thousand Separator · 12 lines
- Time Needed to Buy Tickets · 17 lines
- Toeplitz Matrix · 7 lines
- Total Appeal of A String · 26 lines
- Two Out of Three · 17 lines
- Uncommon Words from Two Sentences · 15 lines
- Unique Paths · 9 lines
- Unique Substrings in Wraparound String · 11 lines
- Valid Anagram · 8 lines
- Validate IP Address · 17 lines
- Valid Mountain Array · 9 lines
- Valid Palindrome II · 19 lines
- Wiggle Sort II · 114 lines
- Word Subsets · 21 lines
- X of a Kind in a Deck of Cards · 25 lines