Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/warycat/rustgym
Leetcode Solutions in Rust, Advent of Code Solutions in Rust and more
https://github.com/warycat/rustgym
advent-of-code algorithm graph hackerrank hackerrank-solutions interview interview-practice interview-preparation interview-questions leetcode leetcode-rust leetcode-solutions macros rust solutions trie tutorial
Last synced: 2 months ago
JSON representation
Leetcode Solutions in Rust, Advent of Code Solutions in Rust and more
- Host: GitHub
- URL: https://github.com/warycat/rustgym
- Owner: warycat
- License: mit
- Created: 2019-06-26T04:14:32.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-03-25T01:08:18.000Z (almost 2 years ago)
- Last Synced: 2024-10-31T11:33:56.693Z (2 months ago)
- Topics: advent-of-code, algorithm, graph, hackerrank, hackerrank-solutions, interview, interview-practice, interview-preparation, interview-questions, leetcode, leetcode-rust, leetcode-solutions, macros, rust, solutions, trie, tutorial
- Language: Rust
- Homepage: https://rustgym.com
- Size: 4.6 MB
- Stars: 893
- Watchers: 20
- Forks: 86
- Open Issues: 21
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
- awesome-rust - Rust Gym - A big collection of coding interview problems solved in Rust. (Resources / Web programming)
- awesome-rust-cn - Rust Gym - 用Rust解决的编码面试问题大集合. (资源 Resources / 网络编程 Web programming)
- awesome-leetcode - warycat/rustgym
README
# [RUST GYM](http://rustgym.com) Rust Solutions [![Docs Status](https://docs.rs/rustgym/badge.svg)](https://docs.rs/rustgym) [![Rust](https://github.com/warycat/rustgym/workflows/Rust/badge.svg)](https://github.com/warycat/rustgym/actions)
## [Leetcode Solutions in Rust](#leetcode)
## [AdventOfCode Solutions in Rust](#adventofcode)
## [Google Solutions in Rust](#google)This project demonstrates how to create **Data Structures** and to implement **Algorithms** using programming language **Rust**
All the solutions here are crafted with love and their performance beats 99% of other solutions on the leetcode website. Tutorial videos will be added later.### Please subscribe to our [RUST GYM Youtube Channel](https://www.youtube.com/channel/UCV9HzRLPKjI8SttaIYOygsw) for future videos.
Data Structures
- Stack & Queue ( Vec, VecDeque )
- Linked List ( Option> )
- Hash Tables ( HashMap, HashSet )
- Tree Tables ( BTreeMap, BTreeSet )
- Binary Search Tree ( Option>> )
- Binary Heaps & Priority Queue ( BinaryHeap )
- Graphs ( Vec> )
- Union Find ( UnionFind )
- Trie ( Trie )Algorithms
- Bit Manipulation & Numbers
- Stability in Sorting
- Heapsort
- Binary Search
- Kth Smallest Elements
- Permutations
- Subsets
- BFS Graph
- DFS Graph
- Dijkstra’s Algorithm
- Tree Traversals
- BFS
- DFS
- in-order
- pre-order
- post-order
- Topological Sort
- Detect cycle in an undirected graph
- Detect a cycle in a directed graph
- Count connected components in a graph
- Find strongly connected components in a graph
id
Leetcode
Level
1
Two Sum
Easy
9
Palindrome Number
Easy
13
Roman to Integer
Easy
14
Longest Common Prefix
Easy
20
Valid Parentheses
Easy
21
Merge Two Sorted Lists
Easy
26
Remove Duplicates from Sorted Array
Easy
27
Remove Element
Easy
28
Implement strStr()
Easy
35
Search Insert Position
Easy
53
Maximum Subarray
Easy
58
Length of Last Word
Easy
66
Plus One
Easy
67
Add Binary
Easy
69
Sqrt(x)
Easy
70
Climbing Stairs
Easy
83
Remove Duplicates from Sorted List
Easy
88
Merge Sorted Array
Easy
94
Binary Tree Inorder Traversal
Easy
100
Same Tree
Easy
101
Symmetric Tree
Easy
104
Maximum Depth of Binary Tree
Easy
108
Convert Sorted Array to Binary Search Tree
Easy
110
Balanced Binary Tree
Easy
111
Minimum Depth of Binary Tree
Easy
112
Path Sum
Easy
118
Pascal's Triangle
Easy
119
Pascal's Triangle II
Easy
121
Best Time to Buy and Sell Stock
Easy
125
Valid Palindrome
Easy
136
Single Number
Easy
141
Linked List Cycle
Easy
144
Binary Tree Preorder Traversal
Easy
145
Binary Tree Postorder Traversal
Easy
155
Min Stack
Easy
157
Read N Characters Given Read4
Easy
160
Intersection of Two Linked Lists
Easy
163
Missing Ranges
Easy
167
Two Sum II - Input Array Is Sorted
Easy
168
Excel Sheet Column Title
Easy
169
Majority Element
Easy
170
Two Sum III - Data structure design
Easy
171
Excel Sheet Column Number
Easy
190
Reverse Bits
Easy
191
Number of 1 Bits
Easy
202
Happy Number
Easy
203
Remove Linked List Elements
Easy
205
Isomorphic Strings
Easy
206
Reverse Linked List
Easy
217
Contains Duplicate
Easy
219
Contains Duplicate II
Easy
225
Implement Stack using Queues
Easy
226
Invert Binary Tree
Easy
228
Summary Ranges
Easy
231
Power of Two
Easy
232
Implement Queue using Stacks
Easy
234
Palindrome Linked List
Easy
235
Lowest Common Ancestor of a Binary Search Tree
Easy
237
Delete Node in a Linked List
Easy
242
Valid Anagram
Easy
243
Shortest Word Distance
Easy
246
Strobogrammatic Number
Easy
252
Meeting Rooms
Easy
257
Binary Tree Paths
Easy
258
Add Digits
Easy
263
Ugly Number
Easy
266
Palindrome Permutation
Easy
268
Missing Number
Easy
270
Closest Binary Search Tree Value
Easy
278
First Bad Version
Easy
283
Move Zeroes
Easy
290
Word Pattern
Easy
292
Nim Game
Easy
293
Flip Game
Easy
303
Range Sum Query - Immutable
Easy
326
Power of Three
Easy
338
Counting Bits
Easy
342
Power of Four
Easy
344
Reverse String
Easy
345
Reverse Vowels of a String
Easy
346
Moving Average from Data Stream
Easy
349
Intersection of Two Arrays
Easy
350
Intersection of Two Arrays II
Easy
359
Logger Rate Limiter
Easy
367
Valid Perfect Square
Easy
374
Guess Number Higher or Lower
Easy
383
Ransom Note
Easy
387
First Unique Character in a String
Easy
389
Find the Difference
Easy
392
Is Subsequence
Easy
401
Binary Watch
Easy
404
Sum of Left Leaves
Easy
405
Convert a Number to Hexadecimal
Easy
408
Valid Word Abbreviation
Easy
409
Longest Palindrome
Easy
412
Fizz Buzz
Easy
414
Third Maximum Number
Easy
415
Add Strings
Easy
422
Valid Word Square
Easy
434
Number of Segments in a String
Easy
441
Arranging Coins
Easy
448
Find All Numbers Disappeared in an Array
Easy
455
Assign Cookies
Easy
459
Repeated Substring Pattern
Easy
461
Hamming Distance
Easy
463
Island Perimeter
Easy
476
Number Complement
Easy
482
License Key Formatting
Easy
485
Max Consecutive Ones
Easy
492
Construct the Rectangle
Easy
495
Teemo Attacking
Easy
496
Next Greater Element I
Easy
500
Keyboard Row
Easy
501
Find Mode in Binary Search Tree
Easy
504
Base 7
Easy
506
Relative Ranks
Easy
507
Perfect Number
Easy
509
Fibonacci Number
Easy
520
Detect Capital
Easy
521
Longest Uncommon Subsequence I
Easy
530
Minimum Absolute Difference in BST
Easy
541
Reverse String II
Easy
543
Diameter of Binary Tree
Easy
551
Student Attendance Record I
Easy
557
Reverse Words in a String III
Easy
559
Maximum Depth of N-ary Tree
Easy
561
Array Partition I
Easy
563
Binary Tree Tilt
Easy
566
Reshape the Matrix
Easy
572
Subtree of Another Tree
Easy
575
Distribute Candies
Easy
589
N-ary Tree Preorder Traversal
Easy
590
N-ary Tree Postorder Traversal
Easy
594
Longest Harmonious Subsequence
Easy
598
Range Addition II
Easy
599
Minimum Index Sum of Two Lists
Easy
604
Design Compressed String Iterator
Easy
605
Can Place Flowers
Easy
606
Construct String from Binary Tree
Easy
617
Merge Two Binary Trees
Easy
628
Maximum Product of Three Numbers
Easy
637
Average of Levels in Binary Tree
Easy
643
Maximum Average Subarray I
Easy
645
Set Mismatch
Easy
653
Two Sum IV - Input is a BST
Easy
657
Robot Return to Origin
Easy
661
Image Smoother
Easy
671
Second Minimum Node In a Binary Tree
Easy
674
Longest Continuous Increasing Subsequence
Easy
680
Valid Palindrome II
Easy
682
Baseball Game
Easy
693
Binary Number with Alternating Bits
Easy
696
Count Binary Substrings
Easy
697
Degree of an Array
Easy
700
Search in a Binary Search Tree
Easy
703
Kth Largest Element in a Stream
Easy
704
Binary Search
Easy
705
Design HashSet
Easy
706
Design HashMap
Easy
709
To Lower Case
Easy
716
Max Stack
Easy
717
1-bit and 2-bit Characters
Easy
724
Find Pivot Index
Easy
728
Self Dividing Numbers
Easy
733
Flood Fill
Easy
734
Sentence Similarity
Easy
744
Find Smallest Letter Greater Than Target
Easy
746
Min Cost Climbing Stairs
Easy
747
Largest Number At Least Twice of Others
Easy
748
Shortest Completing Word
Easy
760
Find Anagram Mappings
Easy
762
Prime Number of Set Bits in Binary Representation
Easy
766
Toeplitz Matrix
Easy
771
Jewels and Stones
Easy
783
Minimum Distance Between BST Nodes
Easy
796
Rotate String
Easy
800
Similar RGB Color
Easy
804
Unique Morse Code Words
Easy
806
Number of Lines To Write String
Easy
812
Largest Triangle Area
Easy
819
Most Common Word
Easy
821
Shortest Distance to a Character
Easy
824
Goat Latin
Easy
830
Positions of Large Groups
Easy
832
Flipping an Image
Easy
836
Rectangle Overlap
Easy
844
Backspace String Compare
Easy
852
Peak Index in a Mountain Array
Easy
859
Buddy Strings
Easy
860
Lemonade Change
Easy
867
Transpose Matrix
Easy
868
Binary Gap
Easy
872
Leaf-Similar Trees
Easy
876
Middle of the Linked List
Easy
883
Projection Area of 3D Shapes
Easy
884
Uncommon Words from Two Sentences
Easy
888
Fair Candy Swap
Easy
892
Surface Area of 3D Shapes
Easy
896
Monotonic Array
Easy
897
Increasing Order Search Tree
Easy
905
Sort Array By Parity
Easy
908
Smallest Range I
Easy
914
X of a Kind in a Deck of Cards
Easy
917
Reverse Only Letters
Easy
922
Sort Array By Parity II
Easy
925
Long Pressed Name
Easy
929
Unique Email Addresses
Easy
933
Number of Recent Calls
Easy
937
Reorder Data in Log Files
Easy
938
Range Sum of BST
Easy
941
Valid Mountain Array
Easy
942
DI String Match
Easy
944
Delete Columns to Make Sorted
Easy
953
Verifying an Alien Dictionary
Easy
961
N-Repeated Element in Size 2N Array
Easy
965
Univalued Binary Tree
Easy
976
Largest Perimeter Triangle
Easy
977
Squares of a Sorted Array
Easy
989
Add to Array-Form of Integer
Easy
993
Cousins in Binary Tree
Easy
997
Find the Town Judge
Easy
999
Available Captures for Rook
Easy
1002
Find Common Characters
Easy
1005
Maximize Sum Of Array After K Negations
Easy
1009
Complement of Base 10 Integer
Easy
1013
Partition Array Into Three Parts With Equal Sum
Easy
1018
Binary Prefix Divisible By 5
Easy
1021
Remove Outermost Parentheses
Easy
1022
Sum of Root To Leaf Binary Numbers
Easy
1025
Divisor Game
Easy
1030
Matrix Cells in Distance Order
Easy
1037
Valid Boomerang
Easy
1046
Last Stone Weight
Easy
1047
Remove All Adjacent Duplicates In String
Easy
1051
Height Checker
Easy
1056
Confusing Number
Easy
1064
Fixed Point
Easy
1065
Index Pairs of a String
Easy
1071
Greatest Common Divisor of Strings
Easy
1078
Occurrences After Bigram
Easy
1085
Sum of Digits in the Minimum Number
Easy
1086
High Five
Easy
1089
Duplicate Zeros
Easy
1099
Two Sum Less Than K
Easy
1103
Distribute Candies to People
Easy
1108
Defanging an IP Address
Easy
1114
Print in Order
Easy
1118
Number of Days in a Month
Easy
1119
Remove Vowels from a String
Easy
1122
Relative Sort Array
Easy
1128
Number of Equivalent Domino Pairs
Easy
1133
Largest Unique Number
Easy
1134
Armstrong Number
Easy
1137
N-th Tribonacci Number
Easy
1150
Check If a Number Is Majority Element in a Sorted Array
Easy
1154
Day of the Year
Easy
1160
Find Words That Can Be Formed by Characters
Easy
1165
Single-Row Keyboard
Easy
1175
Prime Arrangements
Easy
1176
Diet Plan Performance
Easy
1180
Count Substrings with Only One Distinct Letter
Easy
1184
Distance Between Bus Stops
Easy
1185
Day of the Week
Easy
1189
Maximum Number of Balloons
Easy
1196
How Many Apples Can You Put into the Basket
Easy
1200
Minimum Absolute Difference
Easy
1207
Unique Number of Occurrences
Easy
1213
Intersection of Three Sorted Arrays
Easy
1217
Minimum Cost to Move Chips to The Same Position
Easy
1221
Split a String in Balanced Strings
Easy
1228
Missing Number In Arithmetic Progression
Easy
1232
Check If It Is a Straight Line
Easy
1243
Array Transformation
Easy
1252
Cells with Odd Values in a Matrix
Easy
1260
Shift 2D Grid
Easy
1266
Minimum Time Visiting All Points
Easy
1271
Hexspeak
Easy
1275
Find Winner on a Tic Tac Toe Game
Easy
1279
Traffic Light Controlled Intersection
Easy
1281
Subtract the Product and Sum of Digits of an Integer
Easy
1287
Element Appearing More Than 25% In Sorted Array
Easy
1290
Convert Binary Number in a Linked List to Integer
Easy
1295
Find Numbers with Even Number of Digits
Easy
1299
Replace Elements with Greatest Element on Right Side
Easy
1304
Find N Unique Integers Sum up to Zero
Easy
1309
Decrypt String from Alphabet to Integer Mapping
Easy
1313
Decompress Run-Length Encoded List
Easy
1317
Convert Integer to the Sum of Two No-Zero Integers
Easy
1323
Maximum 69 Number
Easy
1331
Rank Transform of an Array
Easy
1332
Remove Palindromic Subsequences
Easy
1337
The K Weakest Rows in a Matrix
Easy
1342
Number of Steps to Reduce a Number to Zero
Easy
1346
Check If N and Its Double Exist
Easy
1351
Count Negative Numbers in a Sorted Matrix
Easy
1356
Sort Integers by The Number of 1 Bits
Easy
1360
Number of Days Between Two Dates
Easy
1365
How Many Numbers Are Smaller Than the Current Number
Easy
1370
Increasing Decreasing String
Easy
1374
Generate a String With Characters That Have Odd Counts
Easy
1380
Lucky Numbers in a Matrix
Easy
1385
Find the Distance Value Between Two Arrays
Easy
1389
Create Target Array in the Given Order
Easy
1394
Find Lucky Integer in an Array
Easy
1399
Count Largest Group
Easy
1403
Minimum Subsequence in Non-Increasing Order
Easy
1408
String Matching in an Array
Easy
1413
Minimum Value to Get Positive Step by Step Sum
Easy
1417
Reformat The String
Easy
1422
Maximum Score After Splitting a String
Easy
1426
Counting Elements
Easy
1427
Perform String Shifts
Easy
1431
Kids With the Greatest Number of Candies
Easy
1436
Destination City
Easy
1437
Check If All 1's Are at Least Length K Places Away
Easy
1441
Build an Array With Stack Operations
Easy
1446
Consecutive Characters
Easy
1450
Number of Students Doing Homework at a Given Time
Easy
1455
Check If a Word Occurs As a Prefix of Any Word in a Sentence
Easy
1460
Make Two Arrays Equal by Reversing Sub-arrays
Easy
1464
Maximum Product of Two Elements in an Array
Easy
1469
Find All The Lonely Nodes
Easy
1470
Shuffle the Array
Easy
1474
Delete N Nodes After M Nodes of a Linked List
Easy
1475
Final Prices With a Special Discount in a Shop
Easy
1480
Running Sum of 1d Array
Easy
1486
XOR Operation in an Array
Easy
1491
Average Salary Excluding the Minimum and Maximum Salary
Easy
1496
Path Crossing
Easy
1502
Can Make Arithmetic Progression From Sequence
Easy
1507
Reformat Date
Easy
1512
Number of Good Pairs
Easy
1518
Water Bottles
Easy
1523
Count Odd Numbers in an Interval Range
Easy
1528
Shuffle String
Easy
1534
Count Good Triplets
Easy
1539
Kth Missing Positive Number
Easy
1544
Make The String Great
Easy
1550
Three Consecutive Odds
Easy
1556
Thousand Separator
Easy
1560
Most Visited Sector in a Circular Track
Easy
1566
Detect Pattern of Length M Repeated K or More Times
Easy
1572
Matrix Diagonal Sum
Easy
1576
Replace All ?'s to Avoid Consecutive Repeating Characters
Easy
1582
Special Positions in a Binary Matrix
Easy
1588
Sum of All Odd Length Subarrays
Easy
1592
Rearrange Spaces Between Words
Easy
1598
Crawler Log Folder
Easy
1603
Design Parking System
Easy
1608
Special Array With X Elements Greater Than or Equal X
Easy
1614
Maximum Nesting Depth of the Parentheses
Easy
1619
Mean of Array After Removing Some Elements
Easy
1624
Largest Substring Between Two Equal Characters
Easy
1629
Slowest Key
Easy
1636
Sort Array by Increasing Frequency
Easy
1640
Check Array Formation Through Concatenation
Easy
1646
Get Maximum in Generated Array
Easy
1652
Defuse the Bomb
Easy
1656
Design an Ordered Stream
Easy
1662
Check If Two String Arrays are Equivalent
Easy
1668
Maximum Repeating Substring
Easy
1672
Richest Customer Wealth
Easy
1678
Goal Parser Interpretation
Easy
1684
Count the Number of Consistent Strings
Easy
1688
Count of Matches in Tournament
Easy
1694
Reformat Phone Number
Easy
1700
Number of Students Unable to Eat Lunch
Easy
1704
Determine if String Halves Are Alike
Easy
1708
Largest Subarray Length K
Easy
1710
Maximum Units on a Truck
Easy
1716
Calculate Money in Leetcode Bank
Easy
1720
Decode XORed Array
Easy
1725
Number Of Rectangles That Can Form The Largest Square
Easy
1732
Find the Highest Altitude
Easy
1736
Latest Time by Replacing Hidden Digits
Easy
1742
Maximum Number of Balls in a Box
Easy
1748
Sum of Unique Elements
Easy
1752
Check if Array Is Sorted and Rotated
Easy
1758
Minimum Changes To Make Alternating Binary String
Easy
1763
Longest Nice Substring
Easy
1768
Merge Strings Alternately
Easy
1773
Count Items Matching a Rule
Easy
1779
Find Nearest Point That Has the Same X or Y Coordinate
Easy
1784
Check if Binary String Has at Most One Segment of Ones
Easy
1790
Check if One String Swap Can Make Strings Equal
Easy
1791
Find Center of Star Graph
Easy
1796
Second Largest Digit in a String
Easy
1800
Maximum Ascending Subarray Sum
Easy
1805
Number of Different Integers in a String
Easy
1812
Determine Color of a Chessboard Square
Easy
1816
Truncate Sentence
Easy
1822
Sign of the Product of an Array
Easy
1826
Faulty Sensor
Easy
1827
Minimum Operations to Make the Array Increasing
Easy
1832
Check if the Sentence Is Pangram
Easy
1837
Sum of Digits in Base K
Easy
1844
Replace All Digits with Characters
Easy
1848
Minimum Distance to the Target Element
Easy
1854
Maximum Population Year
Easy
1859
Sorting the Sentence
Easy
1863
Sum of All Subset XOR Totals
Easy
1869
Longer Contiguous Segments of Ones than Zeros
Easy
1876
Substrings of Size Three with Distinct Characters
Easy
1880
Check if Word Equals Summation of Two Words
Easy
1886
Determine Whether Matrix Can Be Obtained By Rotation
Easy
1893
Check if All the Integers in a Range Are Covered
Easy
1897
Redistribute Characters to Make All Strings Equal
Easy
1903
Largest Odd Number in String
Easy
1909
Remove One Element to Make the Array Strictly Increasing
Easy
1913
Maximum Product Difference Between Two Pairs
Easy
1920
Build Array from Permutation
Easy
1925
Count Square Sum Triples
Easy
1929
Concatenation of Array
Easy
1933
Check if String Is Decomposable Into Value-Equal Substrings
Easy
1935
Maximum Number of Words You Can Type
Easy
1941
Check if All Characters Have Equal Number of Occurrences
Easy
1945
Sum of Digits of String After Convert
Easy
1952
Three Divisors
Easy
1957
Delete Characters to Make Fancy String
Easy
1961
Check If String Is a Prefix of Array
Easy
1967
Number of Strings That Appear as Substrings in Word
Easy
1971
Find if Path Exists in Graph
Easy
1974
Minimum Time to Type Word Using Special Typewriter
Easy
1979
Find Greatest Common Divisor of Array
Easy
1984
Minimum Difference Between Highest and Lowest of K Scores
Easy
1991
Find the Middle Index in Array
Easy
1995
Count Special Quadruplets
Easy
2000
Reverse Prefix of Word
Easy
2006
Count Number of Pairs With Absolute Difference K
Easy
2011
Final Value of Variable After Performing Operations
Easy
2016
Maximum Difference Between Increasing Elements
Easy
2022
Convert 1D Array Into 2D Array
Easy
2027
Minimum Moves to Convert String
Easy
2032
Two Out of Three
Easy
2037
Minimum Number of Moves to Seat Everyone
Easy
2042
Check if Numbers Are Ascending in a Sentence
Easy
2047
Number of Valid Words in a Sentence
Easy
2053
Kth Distinct String in an Array
Easy
2057
Smallest Index With Equal Value
Easy
2062
Count Vowel Substrings of a String
Easy
2068
Check Whether Two Strings are Almost Equivalent
Easy
2073
Time Needed to Buy Tickets
Easy
2078
Two Furthest Houses With Different Colors
Easy
2085
Count Common Words With One Occurrence
Easy
2089
Find Target Indices After Sorting Array
Easy
2094
Finding 3-Digit Even Numbers
Easy
2099
Find Subsequence of Length K With the Largest Sum
Easy
2103
Rings and Rods
Easy
2108
Find First Palindromic String in the Array
Easy
2114
Maximum Number of Words Found in Sentences
Easy
2119
A Number After a Double Reversal
Easy
2124
Check if All A's Appears Before All B's
Easy
2129
Capitalize the Title
Easy
2133
Check if Every Row and Column Contains All Numbers
Easy
2138
Divide a String Into Groups of Size k
Easy
2144
Minimum Cost of Buying Candies With Discount
Easy
2148
Count Elements With Strictly Smaller and Greater Elements
Easy
2
Add Two Numbers
Medium
3
Longest Substring Without Repeating Characters
Medium
5
Longest Palindromic Substring
Medium
6
Zigzag Conversion
Medium
7
Reverse Integer
Medium
8
String to Integer (atoi)
Medium
11
Container With Most Water
Medium
12
Integer to Roman
Medium
15
3Sum
Medium
16
3Sum Closest
Medium
17
Letter Combinations of a Phone Number
Medium
18
4Sum
Medium
19
Remove Nth Node From End of List
Medium
22
Generate Parentheses
Medium
24
Swap Nodes in Pairs
Medium
29
Divide Two Integers
Medium
31
Next Permutation
Medium
33
Search in Rotated Sorted Array
Medium
34
Find First and Last Position of Element in Sorted Array
Medium
36
Valid Sudoku
Medium
38
Count and Say
Medium
39
Combination Sum
Medium
40
Combination Sum II
Medium
43
Multiply Strings
Medium
45
Jump Game II
Medium
46
Permutations
Medium
47
Permutations II
Medium
48
Rotate Image
Medium
49
Group Anagrams
Medium
50
Pow(x, n)
Medium
54
Spiral Matrix
Medium
55
Jump Game
Medium
56
Merge Intervals
Medium
57
Insert Interval
Medium
59
Spiral Matrix II
Medium
61
Rotate List
Medium
62
Unique Paths
Medium
63
Unique Paths II
Medium
64
Minimum Path Sum
Medium
71
Simplify Path
Medium
73
Set Matrix Zeroes
Medium
74
Search a 2D Matrix
Medium
75
Sort Colors
Medium
77
Combinations
Medium
78
Subsets
Medium
79
Word Search
Medium
80
Remove Duplicates from Sorted Array II
Medium
81
Search in Rotated Sorted Array II
Medium
82
Remove Duplicates from Sorted List II
Medium
86
Partition List
Medium
89
Gray Code
Medium
90
Subsets II
Medium
91
Decode Ways
Medium
92
Reverse Linked List II
Medium
93
Restore IP Addresses
Medium
95
Unique Binary Search Trees II
Medium
96
Unique Binary Search Trees
Medium
97
Interleaving String
Medium
98
Validate Binary Search Tree
Medium
99
Recover Binary Search Tree
Medium
102
Binary Tree Level Order Traversal
Medium
103
Binary Tree Zigzag Level Order Traversal
Medium
105
Construct Binary Tree from Preorder and Inorder Traversal
Medium
106
Construct Binary Tree from Inorder and Postorder Traversal
Medium
107
Binary Tree Level Order Traversal II
Medium
109
Convert Sorted List to Binary Search Tree
Medium
113
Path Sum II
Medium
114
Flatten Binary Tree to Linked List
Medium
116
Populating Next Right Pointers in Each Node
Medium
117
Populating Next Right Pointers in Each Node II
Medium
120
Triangle
Medium
122
Best Time to Buy and Sell Stock II
Medium
128
Longest Consecutive Sequence
Medium
129
Sum Root to Leaf Numbers
Medium
130
Surrounded Regions
Medium
131
Palindrome Partitioning
Medium
133
Clone Graph
Medium
134
Gas Station
Medium
137
Single Number II
Medium
138
Copy List with Random Pointer
Medium
139
Word Break
Medium
142
Linked List Cycle II
Medium
143
Reorder List
Medium
146
LRU Cache
Medium
147
Insertion Sort List
Medium
148
Sort List
Medium
150
Evaluate Reverse Polish Notation
Medium
151
Reverse Words in a String
Medium
152
Maximum Product Subarray
Medium
153
Find Minimum in Rotated Sorted Array
Medium
156
Binary Tree Upside Down
Medium
159
Longest Substring with At Most Two Distinct Characters
Medium
161
One Edit Distance
Medium
162
Find Peak Element
Medium
165
Compare Version Numbers
Medium
166
Fraction to Recurring Decimal
Medium
172
Factorial Trailing Zeroes
Medium
173
Binary Search Tree Iterator
Medium
179
Largest Number
Medium
186
Reverse Words in a String II
Medium
187
Repeated DNA Sequences
Medium
189
Rotate Array
Medium
198
House Robber
Medium
199
Binary Tree Right Side View
Medium
200
Number of Islands
Medium
201
Bitwise AND of Numbers Range
Medium
204
Count Primes
Medium
207
Course Schedule
Medium
208
Implement Trie (Prefix Tree)
Medium
209
Minimum Size Subarray Sum
Medium
210
Course Schedule II
Medium
211
Design Add and Search Words Data Structure
Medium
213
House Robber II
Medium
215
Kth Largest Element in an Array
Medium
216
Combination Sum III
Medium
220
Contains Duplicate III
Medium
221
Maximal Square
Medium
222
Count Complete Tree Nodes
Medium
223
Rectangle Area
Medium
227
Basic Calculator II
Medium
229
Majority Element II
Medium
230
Kth Smallest Element in a BST
Medium
236
Lowest Common Ancestor of a Binary Tree
Medium
238
Product of Array Except Self
Medium
240
Search a 2D Matrix II
Medium
241
Different Ways to Add Parentheses
Medium
244
Shortest Word Distance II
Medium
245
Shortest Word Distance III
Medium
247
Strobogrammatic Number II
Medium
249
Group Shifted Strings
Medium
250
Count Univalue Subtrees
Medium
251
Flatten 2D Vector
Medium
253
Meeting Rooms II
Medium
254
Factor Combinations
Medium
255
Verify Preorder Sequence in Binary Search Tree
Medium
256
Paint House
Medium
259
3Sum Smaller
Medium
260
Single Number III
Medium
261
Graph Valid Tree
Medium
264
Ugly Number II
Medium
267
Palindrome Permutation II
Medium
271
Encode and Decode Strings
Medium
274
H-Index
Medium
275
H-Index II
Medium
276
Paint Fence
Medium
277
Find the Celebrity
Medium
279
Perfect Squares
Medium
280
Wiggle Sort
Medium
281
Zigzag Iterator
Medium
284
Peeking Iterator
Medium
285
Inorder Successor in BST
Medium
286
Walls and Gates
Medium
287
Find the Duplicate Number
Medium
288
Unique Word Abbreviation
Medium
289
Game of Life
Medium
291
Word Pattern II
Medium
294
Flip Game II
Medium
298
Binary Tree Longest Consecutive Sequence
Medium
299
Bulls and Cows
Medium
300
Longest Increasing Subsequence
Medium
304
Range Sum Query 2D - Immutable
Medium
306
Additive Number
Medium
307
Range Sum Query - Mutable
Medium
309
Best Time to Buy and Sell Stock with Cooldown
Medium
310
Minimum Height Trees
Medium
311
Sparse Matrix Multiplication
Medium
313
Super Ugly Number
Medium
314
Binary Tree Vertical Order Traversal
Medium
316
Remove Duplicate Letters
Medium
318
Maximum Product of Word Lengths
Medium
319
Bulb Switcher
Medium
320
Generalized Abbreviation
Medium
322
Coin Change
Medium
323
Number of Connected Components in an Undirected Graph
Medium
324
Wiggle Sort II
Medium
325
Maximum Size Subarray Sum Equals k
Medium
328
Odd Even Linked List
Medium
331
Verify Preorder Serialization of a Binary Tree
Medium
333
Largest BST Subtree
Medium
334
Increasing Triplet Subsequence
Medium
337
House Robber III
Medium
339
Nested List Weight Sum
Medium
340
Longest Substring with At Most K Distinct Characters
Medium
341
Flatten Nested List Iterator
Medium
343
Integer Break
Medium
347
Top K Frequent Elements
Medium
348
Design Tic-Tac-Toe
Medium
351
Android Unlock Patterns
Medium
353
Design Snake Game
Medium
355
Design Twitter
Medium
356
Line Reflection
Medium
357
Count Numbers with Unique Digits
Medium
360
Sort Transformed Array
Medium
361
Bomb Enemy
Medium
362
Design Hit Counter
Medium
364
Nested List Weight Sum II
Medium
365
Water and Jug Problem
Medium
366
Find Leaves of Binary Tree
Medium
368
Largest Divisible Subset
Medium
369
Plus One Linked List
Medium
370
Range Addition
Medium
371
Sum of Two Integers
Medium
372
Super Pow
Medium
373
Find K Pairs with Smallest Sums
Medium
375
Guess Number Higher or Lower II
Medium
376
Wiggle Subsequence
Medium
377
Combination Sum IV
Medium
378
Kth Smallest Element in a Sorted Matrix
Medium
379
Design Phone Directory
Medium
380
Insert Delete GetRandom O(1)
Medium
382
Linked List Random Node
Medium
384
Shuffle an Array
Medium
385
Mini Parser
Medium
386
Lexicographical Numbers
Medium
388
Longest Absolute File Path
Medium
390
Elimination Game
Medium
393
UTF-8 Validation
Medium
394
Decode String
Medium
395
Longest Substring with At Least K Repeating Characters
Medium
396
Rotate Function
Medium
397
Integer Replacement
Medium
398
Random Pick Index
Medium
399
Evaluate Division
Medium
400
Nth Digit
Medium
402
Remove K Digits
Medium
406
Queue Reconstruction by Height
Medium
413
Arithmetic Slices
Medium
416
Partition Equal Subset Sum
Medium
417
Pacific Atlantic Water Flow
Medium
418
Sentence Screen Fitting
Medium
419
Battleships in a Board
Medium
421
Maximum XOR of Two Numbers in an Array
Medium
423
Reconstruct Original Digits from English
Medium
424
Longest Repeating Character Replacement
Medium
426
Convert Binary Search Tree to Sorted Doubly Linked List
Medium
427
Construct Quad Tree
Medium
429
N-ary Tree Level Order Traversal
Medium
430
Flatten a Multilevel Doubly Linked List
Medium
433
Minimum Genetic Mutation
Medium
435
Non-overlapping Intervals
Medium
436
Find Right Interval
Medium
437
Path Sum III
Medium
438
Find All Anagrams in a String
Medium
439
Ternary Expression Parser
Medium
442
Find All Duplicates in an Array
Medium
443
String Compression
Medium
444
Sequence Reconstruction
Medium
445
Add Two Numbers II
Medium
447
Number of Boomerangs
Medium
449
Serialize and Deserialize BST
Medium
450
Delete Node in a BST
Medium
451
Sort Characters By Frequency
Medium
452
Minimum Number of Arrows to Burst Balloons
Medium
453
Minimum Moves to Equal Array Elements
Medium
454
4Sum II
Medium
456
132 Pattern
Medium
457
Circular Array Loop
Medium
462
Minimum Moves to Equal Array Elements II
Medium
464
Can I Win
Medium
467
Unique Substrings in Wraparound String
Medium
468
Validate IP Address
Medium
469
Convex Polygon
Medium
470
Implement Rand10() Using Rand7()
Medium
473
Matchsticks to Square
Medium
474
Ones and Zeroes
Medium
475
Heaters
Medium
477
Total Hamming Distance
Medium
478
Generate Random Point in a Circle
Medium
481
Magical String
Medium
484
Find Permutation
Medium
486
Predict the Winner
Medium
487
Max Consecutive Ones II
Medium
490
The Maze
Medium
491
Increasing Subsequences
Medium
494
Target Sum
Medium
497
Random Point in Non-overlapping Rectangles
Medium
498
Diagonal Traverse
Medium
503
Next Greater Element II
Medium
505
The Maze II
Medium
508
Most Frequent Subtree Sum
Medium
510
Inorder Successor in BST II
Medium
513
Find Bottom Left Tree Value
Medium
515
Find Largest Value in Each Tree Row
Medium
516
Longest Palindromic Subsequence
Medium
518
Coin Change 2
Medium
519
Random Flip Matrix
Medium
522
Longest Uncommon Subsequence II
Medium
523
Continuous Subarray Sum
Medium
524
Longest Word in Dictionary through Deleting
Medium
525
Contiguous Array
Medium
526
Beautiful Arrangement
Medium
528
Random Pick with Weight
Medium
529
Minesweeper
Medium
531
Lonely Pixel I
Medium
532
K-diff Pairs in an Array
Medium
533
Lonely Pixel II
Medium
535
Encode and Decode TinyURL
Medium
536
Construct Binary Tree from String
Medium
537
Complex Number Multiplication
Medium
538
Convert BST to Greater Tree
Medium
539
Minimum Time Difference
Medium
540
Single Element in a Sorted Array
Medium
542
01 Matrix
Medium
544
Output Contest Matches
Medium
545
Boundary of Binary Tree
Medium
547
Number of Provinces
Medium
549
Binary Tree Longest Consecutive Sequence II
Medium
553
Optimal Division
Medium
554
Brick Wall
Medium
555
Split Concatenated Strings
Medium
556
Next Greater Element III
Medium
558
Logical OR of Two Binary Grids Represented as Quad-Trees
Medium
560
Subarray Sum Equals K
Medium
562
Longest Line of Consecutive One in Matrix
Medium
565
Array Nesting
Medium
567
Permutation in String
Medium
573
Squirrel Simulation
Medium
576
Out of Boundary Paths
Medium
581
Shortest Unsorted Continuous Subarray
Medium
582
Kill Process
Medium
583
Delete Operation for Two Strings
Medium
592
Fraction Addition and Subtraction
Medium
593
Valid Square
Medium
609
Find Duplicate File in System
Medium
611
Valid Triangle Number
Medium
616
Add Bold Tag in String
Medium
621
Task Scheduler
Medium
622
Design Circular Queue
Medium
623
Add One Row to Tree
Medium
624
Maximum Distance in Arrays
Medium
625
Minimum Factorization
Medium
633
Sum of Square Numbers
Medium
634
Find the Derangement of An Array
Medium
635
Design Log Storage System
Medium
636
Exclusive Time of Functions
Medium
638
Shopping Offers
Medium
640
Solve the Equation
Medium
641
Design Circular Deque
Medium
646
Maximum Length of Pair Chain
Medium
647
Palindromic Substrings
Medium
648
Replace Words
Medium
649
Dota2 Senate
Medium
650
2 Keys Keyboard
Medium
651
4 Keys Keyboard
Medium
652
Find Duplicate Subtrees
Medium
654
Maximum Binary Tree
Medium
655
Print Binary Tree
Medium
658
Find K Closest Elements
Medium
659
Split Array into Consecutive Subsequences
Medium
662
Maximum Width of Binary Tree
Medium
663
Equal Tree Partition
Medium
665
Non-decreasing Array
Medium
666
Path Sum IV
Medium
667
Beautiful Arrangement II
Medium
669
Trim a Binary Search Tree
Medium
670
Maximum Swap
Medium
672
Bulb Switcher II
Medium
673
Number of Longest Increasing Subsequence
Medium
676
Implement Magic Dictionary
Medium
677
Map Sum Pairs
Medium
678
Valid Parenthesis String
Medium
681
Next Closest Time
Medium
684
Redundant Connection
Medium
686
Repeated String Match
Medium
687
Longest Univalue Path
Medium
688
Knight Probability in Chessboard
Medium
690
Employee Importance
Medium
692
Top K Frequent Words
Medium
694
Number of Distinct Islands
Medium
695
Max Area of Island
Medium
698
Partition to K Equal Sum Subsets
Medium
701
Insert into a Binary Search Tree
Medium
702
Search in a Sorted Array of Unknown Size
Medium
707
Design Linked List
Medium
708
Insert into a Sorted Circular Linked List
Medium
712
Minimum ASCII Delete Sum for Two Strings
Medium
713
Subarray Product Less Than K
Medium
714
Best Time to Buy and Sell Stock with Transaction Fee
Medium
718
Maximum Length of Repeated Subarray
Medium
720
Longest Word in Dictionary
Medium
721
Accounts Merge
Medium
722
Remove Comments
Medium
723
Candy Crush
Medium
725
Split Linked List in Parts
Medium
729
My Calendar I
Medium
731
My Calendar II
Medium
735
Asteroid Collision
Medium
737
Sentence Similarity II
Medium
738
Monotone Increasing Digits
Medium
739
Daily Temperatures
Medium
740
Delete and Earn
Medium
742
Closest Leaf in a Binary Tree
Medium
743
Network Delay Time
Medium
750
Number Of Corner Rectangles
Medium
751
IP to CIDR
Medium
752
Open the Lock
Medium
754
Reach a Number
Medium
755
Pour Water
Medium
756
Pyramid Transition Matrix
Medium
758
Bold Words in String
Medium
763
Partition Labels
Medium
764
Largest Plus Sign
Medium
767
Reorganize String
Medium
769
Max Chunks To Make Sorted
Medium
775
Global and Local Inversions
Medium
776
Split BST
Medium
777
Swap Adjacent in LR String
Medium
779
K-th Symbol in Grammar
Medium
781
Rabbits in Forest
Medium
784
Letter Case Permutation
Medium
785
Is Graph Bipartite?
Medium
787
Cheapest Flights Within K Stops
Medium
788
Rotated Digits
Medium
789
Escape The Ghosts
Medium
790
Domino and Tromino Tiling
Medium
791
Custom Sort String
Medium
792
Number of Matching Subsequences
Medium
794
Valid Tic-Tac-Toe State
Medium
795
Number of Subarrays with Bounded Maximum
Medium
797
All Paths From Source to Target
Medium
799
Champagne Tower
Medium
802
Find Eventual Safe States
Medium
807
Max Increase to Keep City Skyline
Medium
808
Soup Servings
Medium
809
Expressive Words
Medium
811
Subdomain Visit Count
Medium
813
Largest Sum of Averages
Medium
814
Binary Tree Pruning
Medium
816
Ambiguous Coordinates
Medium
817
Linked List Components
Medium
820
Short Encoding of Words
Medium
822
Card Flipping Game
Medium
823
Binary Trees With Factors
Medium
825
Friends Of Appropriate Ages
Medium
826
Most Profit Assigning Work
Medium
831
Masking Personal Information
Medium
833
Find And Replace in String
Medium
835
Image Overlap
Medium
837
New 21 Game
Medium
838
Push Dominoes
Medium
840
Magic Squares In Grid
Medium
841
Keys and Rooms
Medium
842
Split Array into Fibonacci Sequence
Medium
845
Longest Mountain in Array
Medium
846
Hand of Straights
Medium
848
Shifting Letters
Medium
849
Maximize Distance to Closest Person
Medium
851
Loud and Rich
Medium
853
Car Fleet
Medium
855
Exam Room
Medium
856
Score of Parentheses
Medium
858
Mirror Reflection
Medium
861
Score After Flipping Matrix
Medium
863
All Nodes Distance K in Binary Tree
Medium
865
Smallest Subtree with all the Deepest Nodes
Medium
866
Prime Palindrome
Medium
869
Reordered Power of 2
Medium
870
Advantage Shuffle
Medium
873
Length of Longest Fibonacci Subsequence
Medium
874
Walking Robot Simulation
Medium
875
Koko Eating Bananas
Medium
877
Stone Game
Medium
880
Decoded String at Index
Medium
881
Boats to Save People
Medium
885
Spiral Matrix III
Medium
886
Possible Bipartition
Medium
889
Construct Binary Tree from Preorder and Postorder Traversal
Medium
890
Find and Replace Pattern
Medium
893
Groups of Special-Equivalent Strings
Medium
894
All Possible Full Binary Trees
Medium
898
Bitwise ORs of Subarrays
Medium
900
RLE Iterator
Medium
901
Online Stock Span
Medium
904
Fruit Into Baskets
Medium
907
Sum of Subarray Minimums
Medium
909
Snakes and Ladders
Medium
910
Smallest Range II
Medium
911
Online Election
Medium
912
Sort an Array
Medium
915
Partition Array into Disjoint Intervals
Medium
916
Word Subsets
Medium
918
Maximum Sum Circular Subarray
Medium
919
Complete Binary Tree Inserter
Medium
921
Minimum Add to Make Parentheses Valid
Medium
923
3Sum With Multiplicity
Medium
926
Flip String to Monotone Increasing
Medium
930
Binary Subarrays With Sum
Medium
931
Minimum Falling Path Sum
Medium
932
Beautiful Array
Medium
934
Shortest Bridge
Medium
935
Knight Dialer
Medium
939
Minimum Area Rectangle
Medium
945
Minimum Increment to Make Array Unique
Medium
946
Validate Stack Sequences
Medium
947
Most Stones Removed with Same Row or Column
Medium
948
Bag of Tokens
Medium
949
Largest Time for Given Digits
Medium
950
Reveal Cards In Increasing Order
Medium
951
Flip Equivalent Binary Trees
Medium
954
Array of Doubled Pairs
Medium
955
Delete Columns to Make Sorted II
Medium
957
Prison Cells After N Days
Medium
958
Check Completeness of a Binary Tree
Medium
959
Regions Cut By Slashes
Medium
962
Maximum Width Ramp
Medium
963
Minimum Area Rectangle II
Medium
966
Vowel Spellchecker
Medium
967
Numbers With Same Consecutive Differences
Medium
969
Pancake Sorting
Medium
970
Powerful Integers
Medium
971
Flip Binary Tree To Match Preorder Traversal
Medium
973
K Closest Points to Origin
Medium
974
Subarray Sums Divisible by K
Medium
978
Longest Turbulent Subarray
Medium
979
Distribute Coins in Binary Tree
Medium
981
Time Based Key-Value Store
Medium
983
Minimum Cost For Tickets
Medium
984
String Without AAA or BBB
Medium
985
Sum of Even Numbers After Queries
Medium
986
Interval List Intersections
Medium
988
Smallest String Starting From Leaf
Medium
990
Satisfiability of Equality Equations
Medium
991
Broken Calculator
Medium
994
Rotting Oranges
Medium
998
Maximum Binary Tree II
Medium
1003
Check If Word Is Valid After Substitutions
Medium
1004
Max Consecutive Ones III
Medium
1006
Clumsy Factorial
Medium
1007
Minimum Domino Rotations For Equal Row
Medium
1008
Construct Binary Search Tree from Preorder Traversal
Medium
1010
Pairs of Songs With Total Durations Divisible by 60
Medium
1011
Capacity To Ship Packages Within D Days
Medium
1014
Best Sightseeing Pair
Medium
1015
Smallest Integer Divisible by K
Medium
1016
Binary String With Substrings Representing 1 To N
Medium
1017
Convert to Base -2
Medium
1019
Next Greater Node In Linked List
Medium
1020
Number of Enclaves
Medium
1023
Camelcase Matching
Medium
1024
Video Stitching
Medium
1026
Maximum Difference Between Node and Ancestor
Medium
1027
Longest Arithmetic Subsequence
Medium
1029
Two City Scheduling
Medium
1031
Maximum Sum of Two Non-Overlapping Subarrays
Medium
1033
Moving Stones Until Consecutive
Medium
1034
Coloring A Border
Medium
1035
Uncrossed Lines
Medium
1038
Binary Search Tree to Greater Sum Tree
Medium
1039
Minimum Score Triangulation of Polygon
Medium
1040
Moving Stones Until Consecutive II
Medium
1041
Robot Bounded In Circle
Medium
1042
Flower Planting With No Adjacent
Medium
1043
Partition Array for Maximum Sum
Medium
1048
Longest String Chain
Medium
1049
Last Stone Weight II
Medium
1052
Grumpy Bookstore Owner
Medium
1053
Previous Permutation With One Swap
Medium
1054
Distant Barcodes
Medium
1055
Shortest Way to Form String
Medium
1057
Campus Bikes
Medium
1058
Minimize Rounding Error to Meet Target
Medium
1059
All Paths from Source Lead to Destination
Medium
1060
Missing Element in Sorted Array
Medium
1061
Lexicographically Smallest Equivalent String
Medium
1062
Longest Repeating Substring
Medium
1066
Campus Bikes II
Medium
1072
Flip Columns For Maximum Number of Equal Rows
Medium
1073
Adding Two Negabinary Numbers
Medium
1079
Letter Tile Possibilities
Medium
1080
Insufficient Nodes in Root to Leaf Paths
Medium
1081
Smallest Subsequence of Distinct Characters
Medium
1087
Brace Expansion
Medium
1090
Largest Values From Labels
Medium
1091
Shortest Path in Binary Matrix
Medium
1093
Statistics from a Large Sample
Medium
1094
Car Pooling
Medium
1100
Find K-Length Substrings With No Repeated Characters
Medium
1101
The Earliest Moment When Everyone Become Friends
Medium
1102
Path With Maximum Minimum Value
Medium
1104
Path In Zigzag Labelled Binary Tree
Medium
1105
Filling Bookcase Shelves
Medium
1109
Corporate Flight Bookings
Medium
1110
Delete Nodes And Return Forest
Medium
1111
Maximum Nesting Depth of Two Valid Parentheses Strings
Medium
1115
Print FooBar Alternately
Medium
1116
Print Zero Even Odd
Medium
1117
Building H2O
Medium
1120
Maximum Average Subtree
Medium
1123
Lowest Common Ancestor of Deepest Leaves
Medium
1124
Longest Well-Performing Interval
Medium
1129
Shortest Path with Alternating Colors
Medium
1130
Minimum Cost Tree From Leaf Values
Medium
1131
Maximum of Absolute Value Expression
Medium
1135
Connecting Cities With Minimum Cost
Medium
1136
Parallel Courses
Medium
1138
Alphabet Board Path
Medium
1139
Largest 1-Bordered Square
Medium
1140
Stone Game II
Medium
1143
Longest Common Subsequence
Medium
1144
Decrease Elements To Make Array Zigzag
Medium
1145
Binary Tree Coloring Game
Medium
1146
Snapshot Array
Medium
1151
Minimum Swaps to Group All 1's Together
Medium
1152
Analyze User Website Visit Pattern
Medium
1155
Number of Dice Rolls With Target Sum
Medium
1156
Swap For Longest Repeated Character Substring
Medium
1161
Maximum Level Sum of a Binary Tree
Medium
1162
As Far from Land as Possible
Medium
1166
Design File System
Medium
1167
Minimum Cost to Connect Sticks
Medium
1169
Invalid Transactions
Medium
1170
Compare Strings by Frequency of the Smallest Character
Medium
1171
Remove Zero Sum Consecutive Nodes from Linked List
Medium
1177
Can Make Palindrome from Substring
Medium
1181
Before and After Puzzle
Medium
1182
Shortest Distance to Target Color
Medium
1186
Maximum Subarray Sum with One Deletion
Medium
1188
Design Bounded Blocking Queue
Medium
1190
Reverse Substrings Between Each Pair of Parentheses
Medium
1191
K-Concatenation Maximum Sum
Medium
1195
Fizz Buzz Multithreaded
Medium
1197
Minimum Knight Moves
Medium
1198
Find Smallest Common Element in All Rows
Medium
1201
Ugly Number III
Medium
1202
Smallest String With Swaps
Medium
1208
Get Equal Substrings Within Budget
Medium
1209
Remove All Adjacent Duplicates in String II
Medium
1214
Two Sum BSTs
Medium
1215
Stepping Numbers
Medium
1218
Longest Arithmetic Subsequence of Given Difference
Medium
1219
Path with Maximum Gold
Medium
1222
Queens That Can Attack the King
Medium
1226
The Dining Philosophers
Medium
1227
Airplane Seat Assignment Probability
Medium
1229
Meeting Scheduler
Medium
1230
Toss Strange Coins
Medium
1233
Remove Sub-Folders from the Filesystem
Medium
1234
Replace the Substring for Balanced String
Medium
1236
Web Crawler
Medium
1237
Find Positive Integer Solution for a Given Equation
Medium
1238
Circular Permutation in Binary Representation
Medium
1239
Maximum Length of a Concatenated String with Unique Characters
Medium
1242
Web Crawler Multithreaded
Medium
1244
Design A Leaderboard
Medium
1245
Tree Diameter
Medium
1247
Minimum Swaps to Make Strings Equal
Medium
1248
Count Number of Nice Subarrays
Medium
1249
Minimum Remove to Make Valid Parentheses
Medium
1253
Reconstruct a 2-Row Binary Matrix
Medium
1254
Number of Closed Islands
Medium
1256
Encode Number
Medium
1257
Smallest Common Region
Medium
1258
Synonymous Sentences
Medium
1261
Find Elements in a Contaminated Binary Tree
Medium
1262
Greatest Sum Divisible by Three
Medium
1265
Print Immutable Linked List in Reverse
Medium
1267
Count Servers that Communicate
Medium
1268
Search Suggestions System
Medium
1272
Remove Interval
Medium
1273
Delete Tree Nodes
Medium
1276
Number of Burgers with No Waste of Ingredients
Medium
1277
Count Square Submatrices with All Ones
Medium
1282
Group the People Given the Group Size They Belong To
Medium
1283
Find the Smallest Divisor Given a Threshold
Medium
1286
Iterator for Combination
Medium
1288
Remove Covered Intervals
Medium
1291
Sequential Digits
Medium
1292
Maximum Side Length of a Square with Sum Less than or Equal to Threshold
Medium
1296
Divide Array in Sets of K Consecutive Numbers
Medium
1297
Maximum Number of Occurrences of a Substring
Medium
1300
Sum of Mutated Array Closest to Target
Medium
1302
Deepest Leaves Sum
Medium
1305
All Elements in Two Binary Search Trees
Medium
1306
Jump Game III
Medium
1310
XOR Queries of a Subarray
Medium
1311
Get Watched Videos by Your Friends
Medium
1314
Matrix Block Sum
Medium
1315
Sum of Nodes with Even-Valued Grandparent
Medium
1318
Minimum Flips to Make a OR b Equal to c
Medium
1319
Number of Operations to Make Network Connected
Medium
1324
Print Words Vertically
Medium
1325
Delete Leaves With a Given Value
Medium
1328
Break a Palindrome
Medium
1329
Sort the Matrix Diagonally
Medium
1333
Filter Restaurants by Vegan-Friendly, Price and Distance
Medium
1334
Find the City With the Smallest Number of Neighbors at a Threshold Distance
Medium
1338
Reduce Array Size to The Half
Medium
1339
Maximum Product of Splitted Binary Tree
Medium
1343
Number of Sub-arrays of Size K and Average Greater than or Equal to Threshold
Medium
1344
Angle Between Hands of a Clock
Medium
1347
Minimum Number of Steps to Make Two Strings Anagram
Medium
1348
Tweet Counts Per Frequency
Medium
1352
Product of the Last K Numbers
Medium
1353
Maximum Number of Events That Can Be Attended
Medium
1357
Apply Discount Every n Orders
Medium
1358
Number of Substrings Containing All Three Characters
Medium
1361
Validate Binary Tree Nodes
Medium
1362
Closest Divisors
Medium
1366
Rank Teams by Votes
Medium
1367
Linked List in Binary Tree
Medium
1371
Find the Longest Substring Containing Vowels in Even Counts
Medium
1372
Longest ZigZag Path in a Binary Tree
Medium
1375
Number of Times Binary String Is Prefix-Aligned
Medium
1376
Time Needed to Inform All Employees
Medium
1379
Find a Corresponding Node of a Binary Tree in a Clone of That Tree
Medium
1381
Design a Stack With Increment Operation
Medium
1382
Balance a Binary Search Tree
Medium
1386
Cinema Seat Allocation
Medium
1387
Sort Integers by The Power Value
Medium
1390
Four Divisors
Medium
1391
Check if There is a Valid Path in a Grid
Medium
1395
Count Number of Teams
Medium
1396
Design Underground System
Medium
1400
Construct K Palindrome Strings
Medium
1401
Circle and Rectangle Overlapping
Medium
1404
Number of Steps to Reduce a Number in Binary Representation to One
Medium
1405
Longest Happy String
Medium
1409
Queries on a Permutation With Key
Medium
1410
HTML Entity Parser
Medium
1414
Find the Minimum Number of Fibonacci Numbers Whose Sum Is K
Medium
1415
The k-th Lexicographical String of All Happy Strings of Length n
Medium
1418
Display Table of Food Orders in a Restaurant
Medium
1419
Minimum Number of Frogs Croaking
Medium
1423
Maximum Points You Can Obtain from Cards
Medium
1424
Diagonal Traverse II
Medium
1428
Leftmost Column with at Least a One
Medium
1429
First Unique Number
Medium
1430
Check If a String Is a Valid Sequence from Root to Leaves Path in a Binary Tree
Medium
1432
Max Difference You Can Get From Changing an Integer
Medium
1433
Check If a String Can Break Another String
Medium
1438
Longest Continuous Subarray With Absolute Diff Less Than or Equal to Limit
Medium
1442
Count Triplets That Can Form Two Arrays of Equal XOR
Medium
1443
Minimum Time to Collect All Apples in a Tree
Medium
1447
Simplified Fractions
Medium
1448
Count Good Nodes in Binary Tree
Medium
1451
Rearrange Words in a Sentence
Medium
1452
People Whose List of Favorite Companies Is Not a Subset of Another List
Medium
1456
Maximum Number of Vowels in a Substring of Given Length
Medium
1457
Pseudo-Palindromic Paths in a Binary Tree
Medium
1461
Check If a String Contains All Binary Codes of Size K
Medium
1462
Course Schedule IV
Medium
1465
Maximum Area of a Piece of Cake After Horizontal and Vertical Cuts
Medium
1466
Reorder Routes to Make All Paths Lead to the City Zero
Medium
1471
The k Strongest Values in an Array
Medium
1472
Design Browser History
Medium
1476
Subrectangle Queries
Medium
1477
Find Two Non-overlapping Sub-arrays Each With Target Sum
Medium
1481
Least Number of Unique Integers after K Removals
Medium
1482
Minimum Number of Days to Make m Bouquets
Medium
1485
Clone Binary Tree With Random Pointer
Medium
1487
Making File Names Unique
Medium
1488
Avoid Flood in The City
Medium
1490
Clone N-ary Tree
Medium
1492
The kth Factor of n
Medium
1493
Longest Subarray of 1's After Deleting One Element
Medium
1497
Check If Array Pairs Are Divisible by k
Medium
1498
Number of Subsequences That Satisfy the Given Sum Condition
Medium
1500
Design a File Sharing System
Medium
1503
Last Moment Before All Ants Fall Out of a Plank
Medium
1504
Count Submatrices With All Ones
Medium
1506
Find Root of N-Ary Tree
Medium
1508
Range Sum of Sorted Subarray Sums
Medium
1509
Minimum Difference Between Largest and Smallest Value in Three Moves
Medium
1513
Number of Substrings With Only 1s
Medium
1514
Path with Maximum Probability
Medium
1519
Number of Nodes in the Sub-Tree With the Same Label
Medium
1522
Diameter of N-Ary Tree
Medium
1524
Number of Sub-arrays With Odd Sum
Medium
1525
Number of Good Ways to Split a String
Medium
1529
Minimum Suffix Flips
Medium
1530
Number of Good Leaf Nodes Pairs
Medium
1533
Find the Index of the Large Integer
Medium
1535
Find the Winner of an Array Game
Medium
1536
Minimum Swaps to Arrange a Binary Grid
Medium
1538
Guess the Majority in a Hidden Array
Medium
1540
Can Convert String in K Moves
Medium
1541
Minimum Insertions to Balance a Parentheses String
Medium
1545
Find Kth Bit in Nth Binary String
Medium
1546
Maximum Number of Non-Overlapping Subarrays With Sum Equals Target
Medium
1551
Minimum Operations to Make Array Equal
Medium
1552
Magnetic Force Between Two Balls
Medium
1554
Strings Differ by One Character
Medium
1557
Minimum Number of Vertices to Reach All Nodes
Medium
1558
Minimum Numbers of Function Calls to Make Target Array
Medium
1559
Detect Cycles in 2D Grid
Medium
1561
Maximum Number of Coins You Can Get
Medium
1562
Find Latest Group of Size M
Medium
1564
Put Boxes Into the Warehouse I
Medium
1567
Maximum Length of Subarray With Positive Product
Medium
1570
Dot Product of Two Sparse Vectors
Medium
1573
Number of Ways to Split a String
Medium
1574
Shortest Subarray to be Removed to Make Array Sorted
Medium
1577
Number of Ways Where Square of Number Is Equal to Product of Two Numbers
Medium
1578
Minimum Time to Make Rope Colorful
Medium
1580
Put Boxes Into the Warehouse II
Medium
1583
Count Unhappy Friends
Medium
1584
Min Cost to Connect All Points
Medium
1586
Binary Search Tree Iterator II
Medium
1589
Maximum Sum Obtained of Any Permutation
Medium
1590
Make Sum Divisible by P
Medium
1593
Split a String Into the Max Number of Unique Substrings
Medium
1594
Maximum Non Negative Product in a Matrix
Medium
1599
Maximum Profit of Operating a Centennial Wheel
Medium
1600
Throne Inheritance
Medium
1602
Find Nearest Right Node in Binary Tree
Medium
1604
Alert Using Same Key-Card Three or More Times in a One Hour Period
Medium
1605
Find Valid Matrix Given Row and Column Sums
Medium
1609
Even Odd Tree
Medium
1612
Check If Two Expression Trees are Equivalent
Medium
1615
Maximal Network Rank
Medium
1616
Split Two Strings to Make Palindrome
Medium
1618
Maximum Font to Fit a Sentence in a Screen
Medium
1620
Coordinate With Maximum Network Quality
Medium
1621
Number of Sets of K Non-Overlapping Line Segments
Medium
1625
Lexicographically Smallest String After Applying Operations
Medium
1626
Best Team With No Conflicts
Medium
1628
Design an Expression Tree With Evaluate Function
Medium
1630
Arithmetic Subarrays
Medium
1631
Path With Minimum Effort
Medium
1634
Add Two Polynomials Represented as Linked Lists
Medium
1637
Widest Vertical Area Between Two Points Containing No Points
Medium
1638
Count Substrings That Differ by One Character
Medium
1641
Count Sorted Vowel Strings
Medium
1642
Furthest Building You Can Reach
Medium
1644
Lowest Common Ancestor of a Binary Tree II
Medium
1647
Minimum Deletions to Make Character Frequencies Unique
Medium
1648
Sell Diminishing-Valued Colored Balls
Medium
1650
Lowest Common Ancestor of a Binary Tree III
Medium
1653
Minimum Deletions to Make String Balanced
Medium
1654
Minimum Jumps to Reach Home
Medium
1657
Determine if Two Strings Are Close
Medium
1658
Minimum Operations to Reduce X to Zero
Medium
1660
Correct a Binary Tree
Medium
1663
Smallest String With A Given Numeric Value
Medium
1664
Ways to Make a Fair Array
Medium
1666
Change the Root of a Binary Tree
Medium
1669
Merge In Between Linked Lists
Medium
1670
Design Front Middle Back Queue
Medium
1673
Find the Most Competitive Subsequence
Medium
1674
Minimum Moves to Make Array Complementary
Medium
1676
Lowest Common Ancestor of a Binary Tree IV
Medium
1679
Max Number of K-Sum Pairs
Medium
1680
Concatenation of Consecutive Binary Numbers
Medium
1682
Longest Palindromic Subsequence II
Medium
1685
Sum of Absolute Differences in a Sorted Array
Medium
1686
Stone Game VI
Medium
1689
Partitioning Into Minimum Number Of Deci-Binary Numbers
Medium
1690
Stone Game VII
Medium
1695
Maximum Erasure Value
Medium
1696
Jump Game VI
Medium
1698
Number of Distinct Substrings in a String
Medium
1701
Average Waiting Time
Medium
1702
Maximum Binary String After Change
Medium
1705
Maximum Number of Eaten Apples
Medium
1706
Where Will the Ball Fall
Medium
1711
Count Good Meals
Medium
1712
Ways to Split Array Into Three Subarrays
Medium
1717
Maximum Score From Removing Substrings
Medium
1718
Construct the Lexicographically Largest Valid Sequence
Medium
1721
Swapping Nodes in a Linked List
Medium
1722
Minimize Hamming Distance After Swap Operations
Medium
1726
Tuple with Same Product
Medium
1727
Largest Submatrix With Rearrangements
Medium
1730
Shortest Path to Get Food
Medium
1733
Minimum Number of People to Teach
Medium
1734
Decode XORed Permutation
Medium
1737
Change Minimum Characters to Satisfy One of Three Conditions
Medium
1738
Find Kth Largest XOR Coordinate Value
Medium
1740
Find Distance in a Binary Tree
Medium
1743
Restore the Array From Adjacent Pairs
Medium
1744
Can You Eat Your Favorite Candy on Your Favorite Day?
Medium
1746
Maximum Subarray Sum After One Operation
Medium
1749
Maximum Absolute Sum of Any Subarray
Medium
1750
Minimum Length of String After Deleting Similar Ends
Medium
1753
Maximum Score From Removing Stones
Medium
1754
Largest Merge Of Two Strings
Medium
1756
Design Most Recently Used Queue
Medium
1759
Count Number of Homogenous Substrings
Medium
1760
Minimum Limit of Balls in a Bag
Medium
1762
Buildings With an Ocean View
Medium
1764
Form Array by Concatenating Subarrays of Another Array
Medium
1765
Map of Highest Peak
Medium
1769
Minimum Number of Operations to Move All Balls to Each Box
Medium
1770
Maximum Score from Performing Multiplication Operations
Medium
1772
Sort Features by Popularity
Medium
1774
Closest Dessert Cost
Medium
1775
Equal Sum Arrays With Minimum Number of Operations
Medium
1778
Shortest Path in a Hidden Grid
Medium
1780
Check if Number is a Sum of Powers of Three
Medium
1781
Sum of Beauty of All Substrings
Medium
1785
Minimum Elements to Add to Form a Given Sum
Medium
1786
Number of Restricted Paths From First to Last Node
Medium
1792
Maximum Average Pass Ratio
Medium
1794
Count Pairs of Equal Substrings With Minimum Difference
Medium
1797
Design Authentication Manager
Medium
1798
Maximum Number of Consecutive Values You Can Make
Medium
1801
Number of Orders in the Backlog
Medium
1802
Maximum Value at a Given Index in a Bounded Array
Medium
1804
Implement Trie II (Prefix Tree)
Medium
1806
Minimum Number of Operations to Reinitialize a Permutation
Medium
1807
Evaluate the Bracket Pairs of a String
Medium
1810
Minimum Path Cost in a Hidden Grid
Medium
1813
Sentence Similarity III
Medium
1814
Count Nice Pairs in an Array
Medium
1817
Finding the Users Active Minutes
Medium
1818
Minimum Absolute Sum Difference
Medium
1820
Maximum Number of Accepted Invitations
Medium
1823
Find the Winner of the Circular Game
Medium
1824
Minimum Sideway Jumps
Medium
1828
Queries on Number of Points Inside a Circle
Medium
1829
Maximum XOR for Each Query
Medium
1833
Maximum Ice Cream Bars
Medium
1834
Single-Threaded CPU
Medium
1836
Remove Duplicates From an Unsorted Linked List
Medium
1838
Frequency of the Most Frequent Element
Medium
1839
Longest Substring Of All Vowels in Order
Medium
1845
Seat Reservation Manager
Medium
1846
Maximum Element After Decreasing and Rearranging
Medium
1849
Splitting a String Into Descending Consecutive Values
Medium
1850
Minimum Adjacent Swaps to Reach the Kth Smallest Number
Medium
1852
Distinct Numbers in Each Subarray
Medium
1855
Maximum Distance Between a Pair of Values
Medium
1856
Maximum Subarray Min-Product
Medium
1858
Longest Word With All Prefixes
Medium
1860
Incremental Memory Leak
Medium
1861
Rotating the Box
Medium
1864
Minimum Number of Swaps to Make the Binary String Alternating
Medium
1865
Finding Pairs With a Certain Sum
Medium
1868
Product of Two Run-Length Encoded Arrays
Medium
1870
Minimum Speed to Arrive on Time
Medium
1871
Jump Game VII
Medium
1874
Minimize Product Sum of Two Arrays
Medium
1877
Minimize Maximum Pair Sum in Array
Medium
1878
Get Biggest Three Rhombus Sums in a Grid
Medium
1881
Maximum Value after Insertion
Medium
1882
Process Tasks Using Servers
Medium
1884
Egg Drop With 2 Eggs and N Floors
Medium
1885
Count Pairs in Two Arrays
Medium
1887
Reduction Operations to Make the Array Elements Equal
Medium
1888
Minimum Number of Flips to Make the Binary String Alternating
Medium
1891
Cutting Ribbons
Medium
1894
Find the Student that Will Replace the Chalk
Medium
1895
Largest Magic Square
Medium
1898
Maximum Number of Removable Characters
Medium
1899
Merge Triplets to Form Target Triplet
Medium
1901
Find a Peak Element II
Medium
1902
Depth of BST Given Insertion Order
Medium
1904
The Number of Full Rounds You Have Played
Medium
1905
Count Sub Islands
Medium
1906
Minimum Absolute Difference Queries
Medium
1908
Game of Nim
Medium
1910
Remove All Occurrences of a Substring
Medium
1911
Maximum Alternating Subsequence Sum
Medium
1914
Cyclically Rotating a Grid
Medium
1915
Number of Wonderful Substrings
Medium
1918
Kth Smallest Subarray Sum
Medium
1921
Eliminate Maximum Number of Monsters
Medium
1922
Count Good Numbers
Medium
1926
Nearest Exit from Entrance in Maze
Medium
1927
Sum Game
Medium
1930
Unique Length-3 Palindromic Subsequences
Medium
1936
Add Minimum Number of Rungs
Medium
1937
Maximum Number of Points with Cost
Medium
1940
Longest Common Subsequence Between Sorted Arrays
Medium
1942
The Number of the Smallest Unoccupied Chair
Medium
1943
Describe the Painting
Medium
1946
Largest Number After Mutating Substring
Medium
1947
Maximum Compatibility Score Sum
Medium
1950
Maximum of Minimum Values in All Subarrays
Medium
1953
Maximum Number of Weeks for Which You Can Work
Medium
1954
Minimum Garden Perimeter to Collect Enough Apples
Medium
1958
Check if Move is Legal
Medium
1959
Minimum Total Space Wasted With K Resizing Operations
Medium
1962
Remove Stones to Minimize the Total
Medium
1963
Minimum Number of Swaps to Make the String Balanced
Medium
1966
Binary Searchable Numbers in an Unsorted Array
Medium
1968
Array With Elements Not Equal to Average of Neighbors
Medium
1969
Minimum Non-Zero Product of the Array Elements
Medium
1973
Count Nodes Equal to Sum of Descendants
Medium
1975
Maximum Matrix Sum
Medium
1976
Number of Ways to Arrive at Destination
Medium
1980
Find Unique Binary String
Medium
1981
Minimize the Difference Between Target and Chosen Elements
Medium
1983
Widest Pair of Indices With Equal Range Sum
Medium
1985
Find the Kth Largest Integer in the Array
Medium
1986
Minimum Number of Work Sessions to Finish the Tasks
Medium
1989
Maximum Number of People That Can Be Caught in Tag
Medium
1992
Find All Groups of Farmland
Medium
1993
Operations on Tree
Medium
1996
The Number of Weak Characters in the Game
Medium
1997
First Day Where You Have Been in All the Rooms
Medium
1999
Smallest Greater Multiple Made of Two Digits
Medium
2001
Number of Pairs of Interchangeable Rectangles
Medium
2002
Maximum Product of the Length of Two Palindromic Subsequences
Medium
2007
Find Original Array From Doubled Array
Medium
2008
Maximum Earnings From Taxi
Medium
2012
Sum of Beauty in the Array
Medium
2013
Detect Squares
Medium
2015
Average Height of Buildings in Each Segment
Medium
2017
Grid Game
Medium
2018
Check if Word Can Be Placed In Crossword
Medium
2021
Brightest Position on Street
Medium
2023
Number of Pairs of Strings With Concatenation Equal to Target
Medium
2024
Maximize the Confusion of an Exam
Medium
2028
Find Missing Observations
Medium
2029
Stone Game IX
Medium
2031
Count Subarrays With More Ones Than Zeros
Medium
2033
Minimum Operations to Make a Uni-Value Grid
Medium
2034
Stock Price Fluctuation
Medium
2036
Maximum Alternating Subarray Sum
Medium
2038
Remove Colored Pieces if Both Neighbors are the Same Color
Medium
2039
The Time When the Network Becomes Idle
Medium
2043
Simple Bank System
Medium
2044
Count Number of Maximum Bitwise-OR Subsets
Medium
2046
Sort Linked List Already Sorted Using Absolute Values
Medium
2048
Next Greater Numerically Balanced Number
Medium
2049
Count Nodes With the Highest Score
Medium
2052
Minimum Cost to Separate Sentence Into Rows
Medium
2054
Two Best Non-Overlapping Events
Medium
2055
Plates Between Candles
Medium
2058
Find the Minimum and Maximum Number of Nodes Between Critical Points
Medium
2059
Minimum Operations to Convert Number
Medium
2061
Number of Spaces Cleaning Robot Cleaned
Medium
2063
Vowels of All Substrings
Medium
2064
Minimized Maximum of Products Distributed to Any Store
Medium
2067
Number of Equal Count Substrings
Medium
2069
Walking Robot Simulation II
Medium
2070
Most Beautiful Item for Each Query
Medium
2074
Reverse Nodes in Even Length Groups
Medium
2075
Decode the Slanted Ciphertext
Medium
2077
Paths in Maze That Lead to Same Room
Medium
2079
Watering Plants
Medium
2080
Range Frequency Queries
Medium
2083
Substrings That Begin and End With the Same Letter
Medium
2086
Minimum Number of Buckets Required to Collect Rainwater from Houses
Medium
2087
Minimum Cost Homecoming of a Robot in a Grid
Medium
2090
K Radius Subarray Averages
Medium
2091
Removing Minimum and Maximum From Array
Medium
2093
Minimum Cost to Reach City With Discounts
Medium
2095
Delete the Middle Node of a Linked List
Medium
2096
Step-By-Step Directions From a Binary Tree Node to Another
Medium
2098
Subsequence of Size K With the Largest Even Sum
Medium
2100
Find Good Days to Rob the Bank
Medium
2101
Detonate the Maximum Bombs
Medium
2104
Sum of Subarray Ranges
Medium
2105
Watering Plants II
Medium
2107
Number of Unique Flavors After Sharing K Candies
Medium
2109
Adding Spaces to a String
Medium
2110
Number of Smooth Descent Periods of a Stock
Medium
2113
Elements in Array After Removing and Replacing Elements
Medium
2115
Find All Possible Recipes from Given Supplies
Medium
2116
Check if a Parentheses String Can Be Valid
Medium
2120
Execution of All Suffix Instructions Staying in a Grid
Medium
2121
Intervals Between Identical Elements
Medium
2125
Number of Laser Beams in a Bank
Medium
2126
Destroying Asteroids
Medium
2128
Remove All Ones With Row and Column Flips
Medium
2130
Maximum Twin Sum of a Linked List
Medium
2131
Longest Palindrome by Concatenating Two Letter Words
Medium
2134
Minimum Swaps to Group All 1's Together II
Medium
2135
Count Words Obtained After Adding a Letter
Medium
2137
Pour Water Between Buckets to Make Water Levels Equal
Medium
2139
Minimum Moves to Reach Target Score
Medium
2140
Solving Questions With Brainpower
Medium
2145
Count the Hidden Sequences
Medium
2146
K Highest Ranked Items Within a Price Range
Medium
2149
Rearrange Array Elements by Sign
Medium
2150
Find All Lonely Numbers in the Array
Medium
4
Median of Two Sorted Arrays
Hard
10
Regular Expression Matching
Hard
23
Merge k Sorted Lists
Hard
25
Reverse Nodes in k-Group
Hard
30
Substring with Concatenation of All Words
Hard
32
Longest Valid Parentheses
Hard
37
Sudoku Solver
Hard
41
First Missing Positive
Hard
42
Trapping Rain Water
Hard
44
Wildcard Matching
Hard
51
N-Queens
Hard
52
N-Queens II
Hard
60
Permutation Sequence
Hard
65
Valid Number
Hard
68
Text Justification
Hard
72
Edit Distance
Hard
76
Minimum Window Substring
Hard
84
Largest Rectangle in Histogram
Hard
85
Maximal Rectangle
Hard
87
Scramble String
Hard
115
Distinct Subsequences
Hard
123
Best Time to Buy and Sell Stock III
Hard
124
Binary Tree Maximum Path Sum
Hard
126
Word Ladder II
Hard
127
Word Ladder
Hard
132
Palindrome Partitioning II
Hard
135
Candy
Hard
140
Word Break II
Hard
149
Max Points on a Line
Hard
154
Find Minimum in Rotated Sorted Array II
Hard
158
Read N Characters Given read4 II - Call Multiple Times
Hard
164
Maximum Gap
Hard
174
Dungeon Game
Hard
188
Best Time to Buy and Sell Stock IV
Hard
212
Word Search II
Hard
214
Shortest Palindrome
Hard
218
The Skyline Problem
Hard
224
Basic Calculator
Hard
233
Number of Digit One
Hard
239
Sliding Window Maximum
Hard
248
Strobogrammatic Number III
Hard
265
Paint House II
Hard
269
Alien Dictionary
Hard
272
Closest Binary Search Tree Value II
Hard
273
Integer to English Words
Hard
282
Expression Add Operators
Hard
295
Find Median from Data Stream
Hard
296
Best Meeting Point
Hard
297
Serialize and Deserialize Binary Tree
Hard
301
Remove Invalid Parentheses
Hard
302
Smallest Rectangle Enclosing Black Pixels
Hard
305
Number of Islands II
Hard
308
Range Sum Query 2D - Mutable
Hard
312
Burst Balloons
Hard
315
Count of Smaller Numbers After Self
Hard
317
Shortest Distance from All Buildings
Hard
321
Create Maximum Number
Hard
327
Count of Range Sum
Hard
329
Longest Increasing Path in a Matrix
Hard
330
Patching Array
Hard
332
Reconstruct Itinerary
Hard
335
Self Crossing
Hard
336
Palindrome Pairs
Hard
352
Data Stream as Disjoint Intervals
Hard
354
Russian Doll Envelopes
Hard
358
Rearrange String k Distance Apart
Hard
363
Max Sum of Rectangle No Larger Than K
Hard
381
Insert Delete GetRandom O(1) - Duplicates allowed
Hard
391
Perfect Rectangle
Hard
403
Frog Jump
Hard
407
Trapping Rain Water II
Hard
410
Split Array Largest Sum
Hard
411
Minimum Unique Word Abbreviation
Hard
420
Strong Password Checker
Hard
425
Word Squares
Hard
428
Serialize and Deserialize N-ary Tree
Hard
431
Encode N-ary Tree to Binary Tree
Hard
432
All O`one Data Structure
Hard
440
K-th Smallest in Lexicographical Order
Hard
446
Arithmetic Slices II - Subsequence
Hard
458
Poor Pigs
Hard
460
LFU Cache
Hard
465
Optimal Account Balancing
Hard
466
Count The Repetitions
Hard
471
Encode String with Shortest Length
Hard
472
Concatenated Words
Hard
479
Largest Palindrome Product
Hard
480
Sliding Window Median
Hard
483
Smallest Good Base
Hard
488
Zuma Game
Hard
489
Robot Room Cleaner
Hard
493
Reverse Pairs
Hard
499
The Maze III
Hard
502
IPO
Hard
514
Freedom Trail
Hard
517
Super Washing Machines
Hard
527
Word Abbreviation
Hard
546
Remove Boxes
Hard
548
Split Array with Equal Sum
Hard
552
Student Attendance Record II
Hard
564
Find the Closest Palindrome
Hard
568
Maximum Vacation Days
Hard
587
Erect the Fence
Hard
588
Design In-Memory File System
Hard
591
Tag Validator
Hard
600
Non-negative Integers without Consecutive Ones
Hard
629
K Inverse Pairs Array
Hard
630
Course Schedule III
Hard
631
Design Excel Sum Formula
Hard
632
Smallest Range Covering Elements from K Lists
Hard
639
Decode Ways II
Hard
642
Design Search Autocomplete System
Hard
644
Maximum Average Subarray II
Hard
656
Coin Path
Hard
660
Remove 9
Hard
664
Strange Printer
Hard
668
Kth Smallest Number in Multiplication Table
Hard
675
Cut Off Trees for Golf Event
Hard
679
24 Game
Hard
683
K Empty Slots
Hard
685
Redundant Connection II
Hard
689
Maximum Sum of 3 Non-Overlapping Subarrays
Hard
691
Stickers to Spell Word
Hard
699
Falling Squares
Hard
710
Random Pick with Blacklist
Hard
711
Number of Distinct Islands II
Hard
715
Range Module
Hard
719
Find K-th Smallest Pair Distance
Hard
726
Number of Atoms
Hard
727
Minimum Window Subsequence
Hard
730
Count Different Palindromic Subsequences
Hard
732
My Calendar III
Hard
736
Parse Lisp Expression
Hard
741
Cherry Pickup
Hard
745
Prefix and Suffix Search
Hard
749
Contain Virus
Hard
753
Cracking the Safe
Hard
757
Set Intersection Size At Least Two
Hard
759
Employee Free Time
Hard
761
Special Binary String
Hard
765
Couples Holding Hands
Hard
768
Max Chunks To Make Sorted II
Hard
770
Basic Calculator IV
Hard
772
Basic Calculator III
Hard
773
Sliding Puzzle
Hard
774
Minimize Max Distance to Gas Station
Hard
778
Swim in Rising Water
Hard
780
Reaching Points
Hard
782
Transform to Chessboard
Hard
786
K-th Smallest Prime Fraction
Hard
793
Preimage Size of Factorial Zeroes Function
Hard
798
Smallest Rotation with Highest Score
Hard
801
Minimum Swaps To Make Sequences Increasing
Hard
803
Bricks Falling When Hit
Hard
805
Split Array With Same Average
Hard
810
Chalkboard XOR Game
Hard
815
Bus Routes
Hard
818
Race Car
Hard
827
Making A Large Island
Hard
828
Count Unique Characters of All Substrings of a Given String
Hard
829
Consecutive Numbers Sum
Hard
834
Sum of Distances in Tree
Hard
839
Similar String Groups
Hard
843
Guess the Word
Hard
847
Shortest Path Visiting All Nodes
Hard
850
Rectangle Area II
Hard
854
K-Similar Strings
Hard
857
Minimum Cost to Hire K Workers
Hard
862
Shortest Subarray with Sum at Least K
Hard
864
Shortest Path to Get All Keys
Hard
871
Minimum Number of Refueling Stops
Hard
878
Nth Magical Number
Hard
879
Profitable Schemes
Hard
882
Reachable Nodes In Subdivided Graph
Hard
887
Super Egg Drop
Hard
891
Sum of Subsequence Widths
Hard
895
Maximum Frequency Stack
Hard
899
Orderly Queue
Hard
902
Numbers At Most N Given Digit Set
Hard
903
Valid Permutations for DI Sequence
Hard
906
Super Palindromes
Hard
913
Cat and Mouse
Hard
920
Number of Music Playlists
Hard
924
Minimize Malware Spread
Hard
927
Three Equal Parts
Hard
928
Minimize Malware Spread II
Hard
936
Stamping The Sequence
Hard
940
Distinct Subsequences II
Hard
943
Find the Shortest Superstring
Hard
952
Largest Component Size by Common Factor
Hard
956
Tallest Billboard
Hard
960
Delete Columns to Make Sorted III
Hard
964
Least Operators to Express Number
Hard
968
Binary Tree Cameras
Hard
972
Equal Rational Numbers
Hard
975
Odd Even Jump
Hard
980
Unique Paths III
Hard
982
Triples with Bitwise AND Equal To Zero
Hard
987
Vertical Order Traversal of a Binary Tree
Hard
992
Subarrays with K Different Integers
Hard
995
Minimum Number of K Consecutive Bit Flips
Hard
996
Number of Squareful Arrays
Hard
1000
Minimum Cost to Merge Stones
Hard
1001
Grid Illumination
Hard
1012
Numbers With Repeated Digits
Hard
1028
Recover a Tree From Preorder Traversal
Hard
1032
Stream of Characters
Hard
1036
Escape a Large Maze
Hard
1044
Longest Duplicate Substring
Hard
1063
Number of Valid Subarrays
Hard
1067
Digit Count in Range
Hard
1074
Number of Submatrices That Sum to Target
Hard
1088
Confusing Number II
Hard
1092
Shortest Common Supersequence
Hard
1095
Find in Mountain Array
Hard
1096
Brace Expansion II
Hard
1106
Parsing A Boolean Expression
Hard
1121
Divide Array Into Increasing Sequences
Hard
1125
Smallest Sufficient Team
Hard
1147
Longest Chunked Palindrome Decomposition
Hard
1153
String Transforms Into Another String
Hard
1157
Online Majority Element In Subarray
Hard
1163
Last Substring in Lexicographical Order
Hard
1168
Optimize Water Distribution in a Village
Hard
1172
Dinner Plate Stacks
Hard
1178
Number of Valid Words for Each Puzzle
Hard
1183
Maximum Number of Ones
Hard
1187
Make Array Strictly Increasing
Hard
1192
Critical Connections in a Network
Hard
1199
Minimum Time to Build Blocks
Hard
1203
Sort Items by Groups Respecting Dependencies
Hard
1206
Design Skiplist
Hard
1210
Minimum Moves to Reach Target with Rotations
Hard
1216
Valid Palindrome III
Hard
1220
Count Vowels Permutation
Hard
1223
Dice Roll Simulation
Hard
1224
Maximum Equal Frequency
Hard
1231
Divide Chocolate
Hard
1235
Maximum Profit in Job Scheduling
Hard
1240
Tiling a Rectangle with the Fewest Squares
Hard
1246
Palindrome Removal
Hard
1250
Check If It Is a Good Array
Hard
1255
Maximum Score Words Formed by Letters
Hard
1259
Handshakes That Don't Cross
Hard
1263
Minimum Moves to Move a Box to Their Target Location
Hard
1269
Number of Ways to Stay in the Same Place After Some Steps
Hard
1274
Number of Ships in a Rectangle
Hard
1278
Palindrome Partitioning III
Hard
1284
Minimum Number of Flips to Convert Binary Matrix to Zero Matrix
Hard
1289
Minimum Falling Path Sum II
Hard
1293
Shortest Path in a Grid with Obstacles Elimination
Hard
1298
Maximum Candies You Can Get from Boxes
Hard
1301
Number of Paths with Max Score
Hard
1307
Verbal Arithmetic Puzzle
Hard
1312
Minimum Insertion Steps to Make a String Palindrome
Hard
1316
Distinct Echo Substrings
Hard
1320
Minimum Distance to Type a Word Using Two Fingers
Hard
1326
Minimum Number of Taps to Open to Water a Garden
Hard
1330
Reverse Subarray To Maximize Array Value
Hard
1335
Minimum Difficulty of a Job Schedule
Hard
1340
Jump Game V
Hard
1345
Jump Game IV
Hard
1349
Maximum Students Taking Exam
Hard
1354
Construct Target Array With Multiple Sums
Hard
1359
Count All Valid Pickup and Delivery Options
Hard
1363
Largest Multiple of Three
Hard
1368
Minimum Cost to Make at Least One Valid Path in a Grid
Hard
1373
Maximum Sum BST in Binary Tree
Hard
1377
Frog Position After T Seconds
Hard
1383
Maximum Performance of a Team
Hard
1388
Pizza With 3n Slices
Hard
1392
Longest Happy Prefix
Hard
1397
Find All Good Strings
Hard
1402
Reducing Dishes
Hard
1406
Stone Game III
Hard
1411
Number of Ways to Paint N × 3 Grid
Hard
1416
Restore The Array
Hard
1420
Build Array Where You Can Find The Maximum Exactly K Comparisons
Hard
1425
Constrained Subsequence Sum
Hard
1434
Number of Ways to Wear Different Hats to Each Other
Hard
1439
Find the Kth Smallest Sum of a Matrix With Sorted Rows
Hard
1444
Number of Ways of Cutting a Pizza
Hard
1449
Form Largest Integer With Digits That Add up to Target
Hard
1453
Maximum Number of Darts Inside of a Circular Dartboard
Hard
1458
Max Dot Product of Two Subsequences
Hard
1463
Cherry Pickup II
Hard
1467
Probability of a Two Boxes Having The Same Number of Distinct Balls
Hard
1473
Paint House III
Hard
1478
Allocate Mailboxes
Hard
1483
Kth Ancestor of a Tree Node
Hard
1489
Find Critical and Pseudo-Critical Edges in Minimum Spanning Tree
Hard
1494
Parallel Courses II
Hard
1499
Max Value of Equation
Hard
1505
Minimum Possible Integer After at Most K Adjacent Swaps On Digits
Hard
1510
Stone Game IV
Hard
1515
Best Position for a Service Centre
Hard
1516
Move Sub-Tree of N-Ary Tree
Hard
1520
Maximum Number of Non-Overlapping Substrings
Hard
1521
Find a Value of a Mysterious Function Closest to Target
Hard
1526
Minimum Number of Increments on Subarrays to Form a Target Array
Hard
1531
String Compression II
Hard
1537
Get the Maximum Score
Hard
1542
Find Longest Awesome Substring
Hard
1547
Minimum Cost to Cut a Stick
Hard
1548
The Most Similar Path in a Graph
Hard
1553
Minimum Number of Days to Eat N Oranges
Hard
1563
Stone Game V
Hard
1568
Minimum Number of Days to Disconnect Island
Hard
1569
Number of Ways to Reorder Array to Get Same BST
Hard
1575
Count All Possible Routes
Hard
1579
Remove Max Number of Edges to Keep Graph Fully Traversable
Hard
1585
Check If String Is Transformable With Substring Sort Operations
Hard
1591
Strange Printer II
Hard
1595
Minimum Cost to Connect Two Groups of Points
Hard
1597
Build Binary Expression Tree From Infix Expression
Hard
1601
Maximum Number of Achievable Transfer Requests
Hard
1606
Find Servers That Handled Most Number of Requests
Hard
1610
Maximum Number of Visible Points
Hard
1611
Minimum One Bit Operations to Make Integers Zero
Hard
1617
Count Subtrees With Max Distance Between Cities
Hard
1622
Fancy Sequence
Hard
1627
Graph Connectivity With Threshold
Hard
1632
Rank Transform of a Matrix
Hard
1639
Number of Ways to Form a Target String Given a Dictionary
Hard
1643
Kth Smallest Instructions
Hard
1649
Create Sorted Array through Instructions
Hard
1655
Distribute Repeating Integers
Hard
1659
Maximize Grid Happiness
Hard
1665
Minimum Initial Energy to Finish Tasks
Hard
1671
Minimum Number of Removals to Make Mountain Array
Hard
1675
Minimize Deviation in Array
Hard
1681
Minimum Incompatibility
Hard
1687
Delivering Boxes from Storage to Ports
Hard
1691
Maximum Height by Stacking Cuboids
Hard
1692
Count Ways to Distribute Candies
Hard
1697
Checking Existence of Edge Length Limited Paths
Hard
1703
Minimum Adjacent Swaps for K Consecutive Ones
Hard
1707
Maximum XOR With an Element From Array
Hard
1713
Minimum Operations to Make a Subsequence
Hard
1714
Sum Of Special Evenly-Spaced Elements In Array
Hard
1719
Number Of Ways To Reconstruct A Tree
Hard
1723
Find Minimum Time to Finish All Jobs
Hard
1724
Checking Existence of Edge Length Limited Paths II
Hard
1728
Cat and Mouse II
Hard
1735
Count Ways to Make Array With Product
Hard
1739
Building Boxes
Hard
1745
Palindrome Partitioning IV
Hard
1751
Maximum Number of Events That Can Be Attended II
Hard
1755
Closest Subsequence Sum
Hard
1761
Minimum Degree of a Connected Trio in a Graph
Hard
1766
Tree of Coprimes
Hard
1771
Maximize Palindrome Length From Subsequences
Hard
1776
Car Fleet II
Hard
1782
Count Pairs Of Nodes
Hard
1787
Make the XOR of All Segments Equal to Zero
Hard
1788
Maximize the Beauty of the Garden
Hard
1793
Maximum Score of a Good Subarray
Hard
1799
Maximize Score After N Operations
Hard
1803
Count Pairs With XOR in a Range
Hard
1808
Maximize Number of Nice Divisors
Hard
1815
Maximum Number of Groups Getting Fresh Donuts
Hard
1819
Number of Different Subsequences GCDs
Hard
1825
Finding MK Average
Hard
1830
Minimum Number of Operations to Make String Sorted
Hard
1835
Find XOR Sum of All Pairs Bitwise AND
Hard
1840
Maximum Building Height
Hard
1842
Next Palindrome Using Same Digits
Hard
1847
Closest Room
Hard
1851
Minimum Interval to Include Each Query
Hard
1857
Largest Color Value in a Directed Graph
Hard
1862
Sum of Floored Pairs
Hard
1866
Number of Ways to Rearrange Sticks With K Sticks Visible
Hard
1872
Stone Game VIII
Hard
1879
Minimum XOR Sum of Two Arrays
Hard
1883
Minimum Skips to Arrive at Meeting On Time
Hard
1889
Minimum Space Wasted From Packaging
Hard
1896
Minimum Cost to Change the Final Value of Expression
Hard
1900
The Earliest and Latest Rounds Where Players Compete
Hard
1912
Design Movie Rental System
Hard
1916
Count Ways to Build Rooms in an Ant Colony
Hard
1923
Longest Common Subpath
Hard
1924
Erect the Fence II
Hard
1928
Minimum Cost to Reach Destination in Time
Hard
1931
Painting a Grid With Three Different Colors
Hard
1932
Merge BSTs to Create Single BST
Hard
1938
Maximum Genetic Difference Query
Hard
1944
Number of Visible People in a Queue
Hard
1948
Delete Duplicate Folders in System
Hard
1955
Count Number of Special Subsequences
Hard
1956
Minimum Time For K Virus Variants to Spread
Hard
1960
Maximum Product of the Length of Two Palindromic Substrings
Hard
1964
Find the Longest Valid Obstacle Course at Each Position
Hard
1970
Last Day Where You Can Still Cross
Hard
1977
Number of Ways to Separate Numbers
Hard
1982
Find Array Given Subset Sums
Hard
1987
Number of Unique Good Subsequences
Hard
1994
The Number of Good Subsets
Hard
1998
GCD Sort of an Array
Hard
2003
Smallest Missing Genetic Value in Each Subtree
Hard
2005
Subtree Removal Game with Fibonacci Tree
Hard
2009
Minimum Number of Operations to Make Array Continuous
Hard
2014
Longest Subsequence Repeated k Times
Hard
2019
The Score of Students Solving Math Expression
Hard
2025
Maximum Number of Ways to Partition an Array
Hard
2030
Smallest K-Length Subsequence With Occurrences of a Letter
Hard
2035
Partition Array Into Two Arrays to Minimize Sum Difference
Hard
2040
Kth Smallest Product of Two Sorted Arrays
Hard
2045
Second Minimum Time to Reach Destination
Hard
2050
Parallel Courses III
Hard
2056
Number of Valid Move Combinations On Chessboard
Hard
2060
Check if an Original String Exists Given Two Encoded Strings
Hard
2065
Maximum Path Quality of a Graph
Hard
2071
Maximum Number of Tasks You Can Assign
Hard
2076
Process Restricted Friend Requests
Hard
2081
Sum of k-Mirror Numbers
Hard
2088
Count Fertile Pyramids in a Land
Hard
2092
Find All People With Secret
Hard
2097
Valid Arrangement of Pairs
Hard
2102
Sequentially Ordinal Rank Tracker
Hard
2106
Maximum Fruits Harvested After at Most K Steps
Hard
2111
Minimum Operations to Make the Array K-Increasing
Hard
2117
Abbreviating the Product of a Range
Hard
2122
Recover the Original Array
Hard
2123
Minimum Operations to Remove Adjacent Ones in Matrix
Hard
2127
Maximum Employees to Be Invited to a Meeting
Hard
2132
Stamping the Grid
Hard
2136
Earliest Possible Day of Full Bloom
Hard
2141
Maximum Running Time of N Computers
Hard
2143
Choose Numbers From Two Arrays in Range
Hard
2147
Number of Ways to Divide a Long Corridor
Hard
2151
Maximum Good People Based on Statements
Hard
Year
Day
AdventOfCode
2015
1
Not Quite Lisp
2015
2
I Was Told There Would Be No Math
2015
3
Perfectly Spherical Houses in a Vacuum
2015
4
The Ideal Stocking Stuffer
2015
5
Doesn't He Have Intern-Elves For This?
2015
6
Probably a Fire Hazard
2015
7
Some Assembly Required
2015
8
Matchsticks
2015
9
All in a Single Night
2015
10
Elves Look, Elves Say
2015
11
Corporate Policy
2015
12
JSAbacusFramework.io
2020
1
Report Repair
2020
2
Password Philosophy
2020
3
Toboggan Trajectory
2020
4
Passport Processing
2020
5
Binary Boarding
2020
6
Custom Customs
2020
7
Handy Haversacks
2020
8
Handheld Halting
2020
9
Encoding Error
2020
10
Adapter Array
2020
11
Seating System
2020
12
Rain Risk
2020
13
Shuttle Search
2020
14
Docking Data
2020
15
Rambunctious Recitation
2020
16
Ticket Translation
2020
17
Conway Cubes
2020
18
Operation Order
2020
19
Monster Messages
Division
Year
Round
CodeJam
2008
1
fly swatter
KickStart
2013
1
moist
KickStart
2013
1
captain hammer
KickStart
2013
1
bad horse
KickStart
2020
1
allocation
KickStart
2021
1
k goodness string
KickStart
2021
1
l shaped plots
KickStart
2021
1
rabbit house
KickStart
2021
1
checksum