LeetCode Problems' Solutions
1

LeetCode

LeetCode Problems' Solutions

# Title Solution Difficulty
1 Two Sum Go Easy
2 Add Two Numbers Go Medium
3 Longest Substring Without Repeating Characters Go Medium
4 Median of Two Sorted Arrays Go Hard
5 Longest Palindromic Substring Go Medium
6 ZigZag Conversion Go Medium
7 Reverse Integer Go Easy
8 String to Integer (atoi) Go Medium
9 Palindrome Number Go Easy
10 Regular Expression Matching Go Hard
11 Container With Most Water Go Medium
12 Integer to Roman Go Medium
13 Roman to Integer Go Easy
14 Longest Common Prefix Go Easy
15 3Sum Go Medium
16 3Sum Closest Go Medium
17 Letter Combinations of a Phone Number Go Medium
18 4Sum Go Medium
19 Remove Nth Node From End of List Go Medium
20 Valid Parentheses Go Easy
21 Merge Two Sorted Lists Go Easy
22 Generate Parentheses Go Medium
23 Merge k Sorted Lists Go Hard
24 Swap Nodes in Pairs Go Medium
25 Reverse Nodes in k-Group Go Hard
26 Remove Duplicates from Sorted Array Go Easy
27 Remove Element Go Easy
28 Implement strStr() Go Easy
29 Divide Two Integers Go Medium
30 Substring with Concatenation of All Words Go Hard
31 Next Permutation Go Medium
32 Longest Valid Parentheses Go Hard
33 Search in Rotated Sorted Array Go Medium
34 Find First and Last Position of Element in Sorted Array Go Medium
35 Search Insert Position Go Easy
36 Valid Sudoku Go Medium
37 Sudoku Solver Go Hard
38 Count and Say Go Easy
39 Combination Sum Go Medium
40 Combination Sum II Go Medium
41 First Missing Positive Go Hard
42 Trapping Rain Water Go Hard
43 Multiply Strings Go Medium
44 Wildcard Matching Go Hard
45 Jump Game II Go Hard
46 Permutations Go Medium
47 Permutations II Go Medium
48 Rotate Image Go Medium
49 Group Anagrams Go Medium
50 Pow(x, n) Go Medium
51 N-Queens Go Hard
52 N-Queens II Go Hard
53 Maximum Subarray Go Easy
54 Spiral Matrix Go Medium
55 Jump Game Go Medium
56 Merge Intervals Go Medium
57 Insert Interval Go Hard
58 Length of Last Word Go Easy
59 Spiral Matrix II Go Medium
60 Permutation Sequence Go Medium
61 Rotate List Go Medium
62 Unique Paths Go Medium
63 Unique Paths II Go Medium
64 Minimum Path Sum Go Medium
65 Valid Number Go Hard
66 Plus One Go Easy
67 Add Binary Go Easy
68 Text Justification Go Hard
69 Sqrt(x) Go Easy
70 Climbing Stairs Go Easy
71 Simplify Path Go Medium
72 Edit Distance Go Hard
73 Set Matrix Zeroes Go Medium
74 Search a 2D Matrix Go Medium
75 Sort Colors Go Medium
76 Minimum Window Substring Go Hard
77 Combinations Go Medium
78 Subsets Go Medium
79 Word Search Go Medium
80 Remove Duplicates from Sorted Array II Go Medium
81 Search in Rotated Sorted Array II Go Medium
82 Remove Duplicates from Sorted List II Go Medium
83 Remove Duplicates from Sorted List Go Easy
84 Largest Rectangle in Histogram Go Hard
85 Maximal Rectangle Go Hard
86 Partition List Go Medium
87 Scramble String Go Hard
88 Merge Sorted Array Go Easy
89 Gray Code Go Medium
90 Subsets II Go Medium
91 Decode Ways Go Medium
92 Reverse Linked List II Go Medium
93 Restore IP Addresses Go Medium
94 Binary Tree Inorder Traversal Go Medium
95 Unique Binary Search Trees II Go Medium
96 Unique Binary Search Trees Go Medium
97 Interleaving String Go Hard
98 Validate Binary Search Tree Go Medium
99 Recover Binary Search Tree Go Hard
100 Same Tree Go Easy
101 Symmetric Tree Go Easy
102 Binary Tree Level Order Traversal Go Medium
103 Binary Tree Zigzag Level Order Traversal Go Medium
104 Maximum Depth of Binary Tree Go Easy
105 Construct Binary Tree from Preorder and Inorder Traversal Go Medium
106 Construct Binary Tree from Inorder and Postorder Traversal Go Medium
107 Binary Tree Level Order Traversal II Go Easy
108 Convert Sorted Array to Binary Search Tree Go Easy
109 Convert Sorted List to Binary Search Tree Go Medium
110 Balanced Binary Tree Go Easy
111 Minimum Depth of Binary Tree Go Easy
112 Path Sum Go Easy
113 Path Sum II Go Medium
114 Flatten Binary Tree to Linked List Go Medium
115 Distinct Subsequences Go Hard
116 Populating Next Right Pointers in Each Node Go Medium
117 Populating Next Right Pointers in Each Node II Go Medium
118 Pascal's Triangle Go Easy
119 Pascal's Triangle II Go Easy
120 Triangle Go Medium
121 Best Time to Buy and Sell Stock Go Easy
122 Best Time to Buy and Sell Stock II Go Easy
123 Best Time to Buy and Sell Stock III Go Hard
124 Binary Tree Maximum Path Sum Go Hard
125 Valid Palindrome Go Easy
126 Word Ladder II Go Hard
127 Word Ladder Go Medium
128 Longest Consecutive Sequence Go Hard
129 Sum Root to Leaf Numbers Go Medium
130 Surrounded Regions Go Medium
131 Palindrome Partitioning Go Medium
132 Palindrome Partitioning II Go Hard
133 Clone Graph Go Medium
134 Gas Station Go Medium
135 Candy Go Hard
136 Single Number Go Easy
137 Single Number II Go Medium
138 Copy List with Random Pointer Go Medium
139 Word Break Go Medium
140 Word Break II Go Hard
141 Linked List Cycle Go Easy
142 Linked List Cycle II Go Medium
143 Reorder List Go Medium
144 Binary Tree Preorder Traversal Go Medium
145 Binary Tree Postorder Traversal Go Hard
146 LRU Cache Go Hard
147 Insertion Sort List Go Medium
148 Sort List Go Medium
149 Max Points on a Line Go Hard
150 Evaluate Reverse Polish Notation Go Medium
151 Reverse Words in a String Go Medium
152 Maximum Product Subarray Go Medium
153 Find Minimum in Rotated Sorted Array Go Medium
154 Find Minimum in Rotated Sorted Array II Go Hard
155 Min Stack Go Easy
156 Binary Tree Upside Down 🔒 Go Medium
157 Read N Characters Given Read4 🔒 Go Easy
158 Read N Characters Given Read4 II - Call multiple times 🔒 Go Hard
159 Longest Substring with At Most Two Distinct Characters 🔒 Go Hard
160 Intersection of Two Linked Lists Go Easy
161 One Edit Distance 🔒 Go Medium
162 Find Peak Element Go Medium
163 Missing Ranges 🔒 Go Medium
164 Maximum Gap Go Hard
165 Compare Version Numbers Go Medium
166 Fraction to Recurring Decimal Go Medium
167 Two Sum II - Input array is sorted Go Easy
168 Excel Sheet Column Title Go Easy
169 Majority Element Go Easy
170 Two Sum III - Data structure design 🔒 Go Easy
171 Excel Sheet Column Number Go Easy
172 Factorial Trailing Zeroes Go Easy
173 Binary Search Tree Iterator Go Medium
174 Dungeon Game Go Hard
175 Combine Two Tables Go Easy
176 Second Highest Salary Go Easy
177 Nth Highest Salary Go Medium
178 Rank Scores Go Medium
179 Largest Number Go Medium
180 Consecutive Numbers Go Medium
181 Employees Earning More Than Their Managers Go Easy
182 Duplicate Emails Go Easy
183 Customers Who Never Order Go Easy
184 Department Highest Salary Go Medium
185 Department Top Three Salaries Go Hard
186 Reverse Words in a String II 🔒 Go Medium
187 Repeated DNA Sequences Go Medium
188 Best Time to Buy and Sell Stock IV Go Hard
189 Rotate Array Go Easy
190 Reverse Bits Go Easy
191 Number of 1 Bits Go Easy
192 Word Frequency Go Medium
193 Valid Phone Numbers Go Easy
194 Transpose File Go Medium
195 Tenth Line Bash Easy
196 Delete Duplicate Emails Go Easy
197 Rising Temperature Go Easy
198 House Robber Go Easy
199 Binary Tree Right Side View Go Medium
200 Number of Islands Go Medium
201 Bitwise AND of Numbers Range Go Medium
202 Happy Number Go Easy
203 Remove Linked List Elements Go Easy
204 Count Primes Go Easy
205 Isomorphic Strings Go Easy
206 Reverse Linked List Go Easy
207 Course Schedule Go Medium
208 Implement Trie (Prefix Tree) Go Medium
209 Minimum Size Subarray Sum Go Medium
210 Course Schedule II Go Medium
211 Add and Search Word - Data structure design Go Medium
212 Word Search II Go Hard
213 House Robber II Go Medium
214 Shortest Palindrome Go Hard
215 Kth Largest Element in an Array Go Medium
216 Combination Sum III Go Medium
217 Contains Duplicate Go Easy
218 The Skyline Problem Go Hard
219 Contains Duplicate II Go Easy
220 Contains Duplicate III Go Medium
221 Maximal Square Go Medium
222 Count Complete Tree Nodes Go Medium
223 Rectangle Area Go Medium
224 Basic Calculator Go Hard
225 Implement Stack using Queues Go Easy
226 Invert Binary Tree Go Easy
227 Basic Calculator II Go Medium
228 Summary Ranges Go Medium
229 Majority Element II Go Medium
230 Kth Smallest Element in a BST Go Medium
231 Power of Two Go Easy
232 Implement Queue using Stacks Go Easy
233 Number of Digit One Go Hard
234 Palindrome Linked List Go Easy
235 Lowest Common Ancestor of a Binary Search Tree Go Easy
236 Lowest Common Ancestor of a Binary Tree Go Medium
237 Delete Node in a Linked List Go Easy
238 Product of Array Except Self Go Medium
239 Sliding Window Maximum Go Hard
240 Search a 2D Matrix II Go Medium
241 Different Ways to Add Parentheses Go Medium
242 Valid Anagram Go Easy
243 Shortest Word Distance 🔒 Go Easy
244 Shortest Word Distance II 🔒 Go Medium
245 Shortest Word Distance III 🔒 Go Medium
246 Strobogrammatic Number 🔒 Go Easy
247 Strobogrammatic Number II 🔒 Go Medium
248 Strobogrammatic Number III 🔒 Go Hard
249 Group Shifted Strings 🔒 Go Medium
250 Count Univalue Subtrees 🔒 Go Medium
251 Flatten 2D Vector 🔒 Go Medium
252 Meeting Rooms 🔒 Go Easy
253 Meeting Rooms II 🔒 Go Medium
254 Factor Combinations 🔒 Go Medium
255 Verify Preorder Sequence in Binary Search Tree 🔒 Go Medium
256 Paint House 🔒 Go Easy
257 Binary Tree Paths Go Easy
258 Add Digits Go Easy
259 3Sum Smaller 🔒 Go Medium
260 Single Number III Go Medium
261 Graph Valid Tree 🔒 Go Medium
262 Trips and Users Go Hard
263 Ugly Number Go Easy
264 Ugly Number II Go Medium
265 Paint House II 🔒 Go Hard
266 Palindrome Permutation 🔒 Go Easy
267 Palindrome Permutation II 🔒 Go Medium
268 Missing Number Go Easy
269 Alien Dictionary 🔒 Go Hard
270 Closest Binary Search Tree Value 🔒 Go Easy
271 Encode and Decode Strings 🔒 Go Medium
272 Closest Binary Search Tree Value II 🔒 Go Hard
273 Integer to English Words Go Hard
274 H-Index Go Medium
275 H-Index II Go Medium
276 Paint Fence 🔒 Go Easy
277 Find the Celebrity 🔒 Go Medium
278 First Bad Version Go Easy
279 Perfect Squares Go Medium
280 Wiggle Sort 🔒 Go Medium
281 Zigzag Iterator 🔒 Go Medium
282 Expression Add Operators Go Hard
283 Move Zeroes Go Easy
284 Peeking Iterator Go Medium
285 Inorder Successor in BST 🔒 Go Medium
286 Walls and Gates 🔒 Go Medium
287 Find the Duplicate Number Go Medium
288 Unique Word Abbreviation 🔒 Go Medium
289 Game of Life Go Medium
290 Word Pattern Go Easy
291 Word Pattern II 🔒 Go Hard
292 Nim Game Go Easy
293 Flip Game 🔒 Go Easy
294 Flip Game II 🔒 Go Medium
295 Find Median from Data Stream Go Hard
296 Best Meeting Point 🔒 Go Hard
297 Serialize and Deserialize Binary Tree Go Hard
298 Binary Tree Longest Consecutive Sequence 🔒 Go Medium
299 Bulls and Cows Go Medium
300 Longest Increasing Subsequence Go Medium
301 Remove Invalid Parentheses Go Hard
302 Smallest Rectangle Enclosing Black Pixels 🔒 Go Hard
303 Range Sum Query - Immutable Go Easy
304 Range Sum Query 2D - Immutable Go Medium
305 Number of Islands II 🔒 Go Hard
306 Additive Number Go Medium
307 Range Sum Query - Mutable Go Medium
308 Range Sum Query 2D - Mutable 🔒 Go Hard
309 Best Time to Buy and Sell Stock with Cooldown Go Medium
310 Minimum Height Trees Go Medium
311 Sparse Matrix Multiplication 🔒 Go Medium
312 Burst Balloons Go Hard
313 Super Ugly Number Go Medium
314 Binary Tree Vertical Order Traversal 🔒 Go Medium
315 Count of Smaller Numbers After Self Go Hard
316 Remove Duplicate Letters Go Hard
317 Shortest Distance from All Buildings 🔒 Go Hard
318 Maximum Product of Word Lengths Go Medium
319 Bulb Switcher Go Medium
320 Generalized Abbreviation 🔒 Go Medium
321 Create Maximum Number Go Hard
322 Coin Change Go Medium
323 Number of Connected Components in an Undirected Graph 🔒 Go Medium
324 Wiggle Sort II Go Medium
325 Maximum Size Subarray Sum Equals k 🔒 Go Medium
326 Power of Three Go Easy
327 Count of Range Sum Go Hard
328 Odd Even Linked List Go Medium
329 Longest Increasing Path in a Matrix Go Hard
330 Patching Array Go Hard
331 Verify Preorder Serialization of a Binary Tree Go Medium
332 Reconstruct Itinerary Go Medium
333 Largest BST Subtree 🔒 Go Medium
334 Increasing Triplet Subsequence Go Medium
335 Self Crossing Go Hard
336 Palindrome Pairs Go Hard
337 House Robber III Go Medium
338 Counting Bits Go Medium
339 Nested List Weight Sum 🔒 Go Easy
340 Longest Substring with At Most K Distinct Characters 🔒 Go Hard
341 Flatten Nested List Iterator Go Medium
342 Power of Four Go Easy
343 Integer Break Go Medium
344 Reverse String Go Easy
345 Reverse Vowels of a String Go Easy
346 Moving Average from Data Stream 🔒 Go Easy
347 Top K Frequent Elements Go Medium
348 Design Tic-Tac-Toe 🔒 Go Medium
349 Intersection of Two Arrays Go Easy
350 Intersection of Two Arrays II Go Easy
351 Android Unlock Patterns 🔒 Go Medium
352 Data Stream as Disjoint Intervals Go Hard
353 Design Snake Game 🔒 Go Medium
354 Russian Doll Envelopes Go Hard
355 Design Twitter Go Medium
356 Line Reflection 🔒 Go Medium
357 Count Numbers with Unique Digits Go Medium
358 Rearrange String k Distance Apart 🔒 Go Hard
359 Logger Rate Limiter 🔒 Go Easy
360 Sort Transformed Array 🔒 Go Medium
361 Bomb Enemy 🔒 Go Medium
362 Design Hit Counter 🔒 Go Medium
363 Max Sum of Rectangle No Larger Than K Go Hard
364 Nested List Weight Sum II 🔒 Go Medium
365 Water and Jug Problem Go Medium
366 Find Leaves of Binary Tree 🔒 Go Medium
367 Valid Perfect Square Go Easy
368 Largest Divisible Subset Go Medium
369 Plus One Linked List 🔒 Go Medium
370 Range Addition 🔒 Go Medium
371 Sum of Two Integers Go Easy
372 Super Pow Go Medium
373 Find K Pairs with Smallest Sums Go Medium
374 Guess Number Higher or Lower Go Easy
375 Guess Number Higher or Lower II Go Medium
376 Wiggle Subsequence Go Medium
377 Combination Sum IV Go Medium
378 Kth Smallest Element in a Sorted Matrix Go Medium
379 Design Phone Directory 🔒 Go Medium
380 Insert Delete GetRandom O(1) Go Medium
381 Insert Delete GetRandom O(1) - Duplicates allowed Go Hard
382 Linked List Random Node Go Medium
383 Ransom Note Go Easy
384 Shuffle an Array Go Medium
385 Mini Parser Go Medium
386 Lexicographical Numbers Go Medium
387 First Unique Character in a String Go Easy
388 Longest Absolute File Path Go Medium
389 Find the Difference Go Easy
390 Elimination Game Go Medium
391 Perfect Rectangle Go Hard
392 Is Subsequence Go Medium
393 UTF-8 Validation Go Medium
394 Decode String Go Medium
395 Longest Substring with At Least K Repeating Characters Go Medium
396 Rotate Function Go Medium
397 Integer Replacement Go Medium
398 Random Pick Index Go Medium
399 Evaluate Division Go Medium
400 Nth Digit Go Easy
401 Binary Watch Go Easy
402 Remove K Digits Go Medium
403 Frog Jump Go Hard
404 Sum of Left Leaves Go Easy
405 Convert a Number to Hexadecimal Go Easy
406 Queue Reconstruction by Height Go Medium
407 Trapping Rain Water II Go Hard
408 Valid Word Abbreviation 🔒 Go Easy
409 Longest Palindrome Go Easy
410 Split Array Largest Sum Go Hard
411 Minimum Unique Word Abbreviation 🔒 Go Hard
412 Fizz Buzz Go Easy
413 Arithmetic Slices Go Medium
414 Third Maximum Number Go Easy
415 Add Strings Go Easy
416 Partition Equal Subset Sum Go Medium
417 Pacific Atlantic Water Flow Go Medium
418 Sentence Screen Fitting 🔒 Go Medium
419 Battleships in a Board Go Medium
420 Strong Password Checker Go Hard
421 Maximum XOR of Two Numbers in an Array Go Medium
422 Valid Word Square 🔒 Go Easy
423 Reconstruct Original Digits from English Go Medium
424 Longest Repeating Character Replacement Go Medium
425 Word Squares 🔒 Go Hard
426 Convert Binary Search Tree to Sorted Doubly Linked List 🔒 Go Medium
427 Construct Quad Tree Go Easy
428 Serialize and Deserialize N-ary Tree 🔒 Go Hard
429 N-ary Tree Level Order Traversal Go Easy
430 Flatten a Multilevel Doubly Linked List Go Medium
431 Encode N-ary Tree to Binary Tree 🔒 Go Hard
432 All O`one Data Structure Go Hard
433 Minimum Genetic Mutation Go Medium
434 Number of Segments in a String Go Easy
435 Non-overlapping Intervals Go Medium
436 Find Right Interval Go Medium
437 Path Sum III Go Easy
438 Find All Anagrams in a String Go Easy
439 Ternary Expression Parser 🔒 Go Medium
440 K-th Smallest in Lexicographical Order Go Hard
441 Arranging Coins Go Easy
442 Find All Duplicates in an Array Go Medium
443 String Compression Go Easy
444 Sequence Reconstruction 🔒 Go Medium
445 Add Two Numbers II Go Medium
446 Arithmetic Slices II - Subsequence Go Hard
447 Number of Boomerangs Go Easy
448 Find All Numbers Disappeared in an Array Go Easy
449 Serialize and Deserialize BST Go Medium
450 Delete Node in a BST Go Medium
451 Sort Characters By Frequency Go Medium
452 Minimum Number of Arrows to Burst Balloons Go Medium
453 Minimum Moves to Equal Array Elements Go Easy
454 4Sum II Go Medium
455 Assign Cookies Go Easy
456 132 Pattern Go Medium
457 Circular Array Loop Go Medium
458 Poor Pigs Go Easy
459 Repeated Substring Pattern Go Easy
460 LFU Cache Go Hard
461 Hamming Distance Go Easy
462 Minimum Moves to Equal Array Elements II Go Medium
463 Island Perimeter Go Easy
464 Can I Win Go Medium
465 Optimal Account Balancing 🔒 Go Hard
466 Count The Repetitions Go Hard
467 Unique Substrings in Wraparound String Go Medium
468 Validate IP Address Go Medium
469 Convex Polygon 🔒 Go Medium
470 Implement Rand10() Using Rand7() Go Medium
471 Encode String with Shortest Length 🔒 Go Hard
472 Concatenated Words Go Hard
473 Matchsticks to Square Go Medium
474 Ones and Zeroes Go Medium
475 Heaters Go Easy
476 Number Complement Go Easy
477 Total Hamming Distance Go Medium
478 Generate Random Point in a Circle Go Medium
479 Largest Palindrome Product Go Easy
480 Sliding Window Median Go Hard
481 Magical String Go Medium
482 License Key Formatting Go Easy
483 Smallest Good Base Go Hard
484 Find Permutation 🔒 Go Medium
485 Max Consecutive Ones Go Easy
486 Predict the Winner Go Medium
487 Max Consecutive Ones II 🔒 Go Medium
488 Zuma Game Go Hard
489 Robot Room Cleaner 🔒 Go Hard
490 The Maze 🔒 Go Medium
491 Increasing Subsequences Go Medium
492 Construct the Rectangle Go Easy
493 Reverse Pairs Go Hard
494 Target Sum Go Medium
495 Teemo Attacking Go Medium
496 Next Greater Element I Go Easy
497 Random Point in Non-overlapping Rectangles Go Medium
498 Diagonal Traverse Go Medium
499 The Maze III 🔒 Go Hard
500 Keyboard Row Go Easy
501 Find Mode in Binary Search Tree Go Easy
502 IPO Go Hard
503 Next Greater Element II Go Medium
504 Base 7 Go Easy
505 The Maze II 🔒 Go Medium
506 Relative Ranks Go Easy
507 Perfect Number Go Easy
508 Most Frequent Subtree Sum Go Medium
513 Find Bottom Left Tree Value Go Medium
514 Freedom Trail Go Hard
515 Find Largest Value in Each Tree Row Go Medium
516 Longest Palindromic Subsequence Go Medium
517 Super Washing Machines Go Hard
518 Coin Change 2 Go Medium
519 Random Flip Matrix Go Medium
520 Detect Capital Go Easy
521 Longest Uncommon Subsequence I Go Easy
522 Longest Uncommon Subsequence II Go Medium
523 Continuous Subarray Sum Go Medium
524 Longest Word in Dictionary through Deleting Go Medium
525 Contiguous Array Go Medium
526 Beautiful Arrangement Go Medium
527 Word Abbreviation 🔒 Go Hard
528 Random Pick with Weight Go Medium
529 Minesweeper Go Medium
530 Minimum Absolute Difference in BST Go Easy
531 Lonely Pixel I 🔒 Go Medium
532 K-diff Pairs in an Array Go Easy
533 Lonely Pixel II 🔒 Go Medium
535 Encode and Decode TinyURL Go Medium
536 Construct Binary Tree from String 🔒 Go Medium
537 Complex Number Multiplication Go Medium
538 Convert BST to Greater Tree Go Easy
539 Minimum Time Difference Go Medium
540 Single Element in a Sorted Array Go Medium
541 Reverse String II Go Easy
542 01 Matrix Go Medium
543 Diameter of Binary Tree Go Easy
544 Output Contest Matches 🔒 Go Medium
545 Boundary of Binary Tree 🔒 Go Medium
546 Remove Boxes Go Hard
547 Friend Circles Go Medium
548 Split Array with Equal Sum 🔒 Go Medium
549 Binary Tree Longest Consecutive Sequence II 🔒 Go Medium
551 Student Attendance Record I Go Easy
552 Student Attendance Record II Go Hard
553 Optimal Division Go Medium
554 Brick Wall Go Medium
555 Split Concatenated Strings 🔒 Go Medium
556 Next Greater Element III Go Medium
557 Reverse Words in a String III Go Easy
558 Quad Tree Intersection Go Easy
559 Maximum Depth of N-ary Tree Go Easy
560 Subarray Sum Equals K Go Medium
561 Array Partition I Go Easy
562 Longest Line of Consecutive One in Matrix 🔒 Go Medium
563 Binary Tree Tilt Go Easy
564 Find the Closest Palindrome Go Hard
565 Array Nesting Go Medium
566 Reshape the Matrix Go Easy
567 Permutation in String Go Medium
568 Maximum Vacation Days 🔒 Go Hard
569 Median Employee Salary 🔒 Go Hard
570 Managers with at Least 5 Direct Reports 🔒 Go Medium
571 Find Median Given Frequency of Numbers 🔒 Go Hard
572 Subtree of Another Tree Go Easy
573 Squirrel Simulation 🔒 Go Medium
574 Winning Candidate 🔒 Go Medium
575 Distribute Candies Go Easy
576 Out of Boundary Paths Go Medium
577 Employee Bonus 🔒 Go Easy
578 Get Highest Answer Rate Question 🔒 Go Medium
579 Find Cumulative Salary of an Employee 🔒 Go Hard
580 Count Student Number in Departments 🔒 Go Medium
581 Shortest Unsorted Continuous Subarray Go Easy
582 Kill Process 🔒 Go Medium
583 Delete Operation for Two Strings Go Medium
584 Find Customer Referee 🔒 Go Easy
585 Investments in 2016 🔒 Go Medium
586 Customer Placing the Largest Number of Orders 🔒 Go Easy
587 Erect the Fence Go Hard
588 Design In-Memory File System 🔒 Go Hard
589 N-ary Tree Preorder Traversal Go Easy
590 N-ary Tree Postorder Traversal Go Easy
591 Tag Validator Go Hard
592 Fraction Addition and Subtraction Go Medium
593 Valid Square Go Medium
594 Longest Harmonious Subsequence Go Easy
595 Big Countries Go Easy
596 Classes More Than 5 Students Go Easy
597 Friend Requests I: Overall Acceptance Rate 🔒 Go Easy
598 Range Addition II Go Easy
599 Minimum Index Sum of Two Lists Go Easy
600 Non-negative Integers without Consecutive Ones Go Hard
601 Human Traffic of Stadium Go Hard
602 Friend Requests II: Who Has the Most Friends 🔒 Go Medium
603 Consecutive Available Seats 🔒 Go Easy
604 Design Compressed String Iterator 🔒 Go Easy
605 Can Place Flowers Go Easy
606 Construct String from Binary Tree Go Easy
607 Sales Person 🔒 Go Easy
608 Tree Node 🔒 Go Medium
609 Find Duplicate File in System Go Medium
610 Triangle Judgement 🔒 Go Easy
611 Valid Triangle Number Go Medium
612 Shortest Distance in a Plane 🔒 Go Medium
613 Shortest Distance in a Line 🔒 Go Easy
614 Second Degree Follower 🔒 Go Medium
615 Average Salary: Departments VS Company 🔒 Go Hard
616 Add Bold Tag in String 🔒 Go Medium
617 Merge Two Binary Trees Go Easy
618 Students Report By Geography 🔒 Go Hard
619 Biggest Single Number 🔒 Go Easy
620 Not Boring Movies Go Easy
621 Task Scheduler Go Medium
622 Design Circular Queue Go Medium
623 Add One Row to Tree Go Medium
624 Maximum Distance in Arrays 🔒 Go Easy
625 Minimum Factorization 🔒 Go Medium
626 Exchange Seats Go Medium
627 Swap Salary Go Easy
628 Maximum Product of Three Numbers Go Easy
629 K Inverse Pairs Array Go Hard
630 Course Schedule III Go Hard
631 Design Excel Sum Formula 🔒 Go Hard
632 Smallest Range Go Hard
633 Sum of Square Numbers Go Easy
634 Find the Derangement of An Array 🔒 Go Medium
635 Design Log Storage System 🔒 Go Medium
636 Exclusive Time of Functions Go Medium
637 Average of Levels in Binary Tree Go Easy
638 Shopping Offers Go Medium
639 Decode Ways II Go Hard
640 Solve the Equation Go Medium
641 Design Circular Deque Go Medium
642 Design Search Autocomplete System 🔒 Go Hard
643 Maximum Average Subarray I Go Easy
644 Maximum Average Subarray II 🔒 Go Hard
645 Set Mismatch Go Easy
646 Maximum Length of Pair Chain Go Medium
647 Palindromic Substrings Go Medium
648 Replace Words Go Medium
649 Dota2 Senate Go Medium
650 2 Keys Keyboard Go Medium
651 4 Keys Keyboard 🔒 Go Medium
652 Find Duplicate Subtrees Go Medium
653 Two Sum IV - Input is a BST Go Easy
654 Maximum Binary Tree Go Medium
655 Print Binary Tree Go Medium
656 Coin Path 🔒 Go Hard
657 Robot Return to Origin Go Easy
658 Find K Closest Elements Go Medium
659 Split Array into Consecutive Subsequences Go Medium
660 Remove 9 🔒 Go Hard
661 Image Smoother Go Easy
662 Maximum Width of Binary Tree Go Medium
663 Equal Tree Partition 🔒 Go Medium
664 Strange Printer Go Hard
665 Non-decreasing Array Go Easy
666 Path Sum IV 🔒 Go Medium
667 Beautiful Arrangement II Go Medium
668 Kth Smallest Number in Multiplication Table Go Hard
669 Trim a Binary Search Tree Go Easy
670 Maximum Swap Go Medium
671 Second Minimum Node In a Binary Tree Go Easy
672 Bulb Switcher II Go Medium
673 Number of Longest Increasing Subsequence Go Medium
674 Longest Continuous Increasing Subsequence Go Easy
675 Cut Off Trees for Golf Event Go Hard
676 Implement Magic Dictionary Go Medium
677 Map Sum Pairs Go Medium
678 Valid Parenthesis String Go Medium
679 24 Game Go Hard
680 Valid Palindrome II Go Easy
681 Next Closest Time 🔒 Go Medium
682 Baseball Game Go Easy
683 K Empty Slots 🔒 Go Hard
684 Redundant Connection Go Medium
685 Redundant Connection II Go Hard
686 Repeated String Match Go Easy
687 Longest Univalue Path Go Easy
688 Knight Probability in Chessboard Go Medium
689 Maximum Sum of 3 Non-Overlapping Subarrays Go Hard
690 Employee Importance Go Easy
691 Stickers to Spell Word Go Hard
692 Top K Frequent Words Go Medium
693 Binary Number with Alternating Bits Go Easy
694 Number of Distinct Islands 🔒 Go Medium
695 Max Area of Island Go Medium
696 Count Binary Substrings Go Easy
697 Degree of an Array Go Easy
698 Partition to K Equal Sum Subsets Go Medium
699 Falling Squares Go Hard
700 Search in a Binary Search Tree Go Easy
701 Insert into a Binary Search Tree Go Medium
702 Search in a Sorted Array of Unknown Size 🔒 Go Medium
703 Kth Largest Element in a Stream Go Easy
704 Binary Search Go Easy
705 Design HashSet Go Easy
706 Design HashMap Go Easy
707 Design Linked List Go Easy
708 Insert into a Cyclic Sorted List 🔒 Go Medium
709 To Lower Case Go Easy
710 Random Pick with Blacklist Go Hard
711 Number of Distinct Islands II 🔒 Go Hard
712 Minimum ASCII Delete Sum for Two Strings Go Medium
713 Subarray Product Less Than K Go Medium
714 Best Time to Buy and Sell Stock with Transaction Fee Go Medium
715 Range Module Go Hard
716 Max Stack 🔒 Go Easy
717 1-bit and 2-bit Characters Go Easy
718 Maximum Length of Repeated Subarray Go Medium
719 Find K-th Smallest Pair Distance Go Hard
720 Longest Word in Dictionary Go Easy
721 Accounts Merge Go Medium
722 Remove Comments Go Medium
723 Candy Crush 🔒 Go Medium
724 Find Pivot Index Go Easy
725 Split Linked List in Parts Go Medium
726 Number of Atoms Go Hard
727 Minimum Window Subsequence 🔒 Go Hard
728 Self Dividing Numbers Go Easy
729 My Calendar I Go Medium
730 Count Different Palindromic Subsequences Go Hard
731 My Calendar II Go Medium
732 My Calendar III Go Hard
733 Flood Fill Go Easy
734 Sentence Similarity 🔒 Go Easy
735 Asteroid Collision Go Medium
736 Parse Lisp Expression Go Hard
737 Sentence Similarity II 🔒 Go Medium
738 Monotone Increasing Digits Go Medium
739 Daily Temperatures Go Medium
740 Delete and Earn Go Medium
741 Cherry Pickup Go Hard
742 Closest Leaf in a Binary Tree 🔒 Go Medium
743 Network Delay Time Go Easy
744 Find Smallest Letter Greater Than Target Go Easy
745 Prefix and Suffix Search Go Hard
746 Min Cost Climbing Stairs Go Easy
747 Largest Number At Least Twice of Others Go Easy
748 Shortest Completing Word Go Easy
749 Contain Virus Go Hard
750 Number Of Corner Rectangles 🔒 Go Medium
751 IP to CIDR 🔒 Go Easy
752 Open the Lock Go Medium
753 Cracking the Safe Go Hard
754 Reach a Number Go Easy
755 Pour Water 🔒 Go Medium
756 Pyramid Transition Matrix Go Medium
757 Set Intersection Size At Least Two Go Hard
758 Bold Words in String 🔒 Go Easy
759 Employee Free Time 🔒 Go Hard
760 Find Anagram Mappings 🔒 Go Easy
761 Special Binary String Go Hard
762 Prime Number of Set Bits in Binary Representation Go Easy
763 Partition Labels Go Medium
764 Largest Plus Sign Go Medium
765 Couples Holding Hands Go Hard
766 Toeplitz Matrix Go Easy
767 Reorganize String Go Medium
768 Max Chunks To Make Sorted II Go Hard
769 Max Chunks To Make Sorted Go Medium
770 Basic Calculator IV Go Hard
771 Jewels and Stones Go Easy
772 Basic Calculator III 🔒 Go Hard
773 Sliding Puzzle Go Hard
774 Minimize Max Distance to Gas Station 🔒 Go Hard
775 Global and Local Inversions Go Medium
776 Split BST 🔒 Go Medium
777 Swap Adjacent in LR String Go Medium
778 Swim in Rising Water Go Hard
779 K-th Symbol in Grammar Go Medium
780 Reaching Points Go Hard
781 Rabbits in Forest Go Medium
782 Transform to Chessboard Go Hard
783 Minimum Distance Between BST Nodes Go Easy
784 Letter Case Permutation Go Easy
785 Is Graph Bipartite? Go Medium
786 K-th Smallest Prime Fraction Go Hard
787 Cheapest Flights Within K Stops Go Medium
788 Rotated Digits Go Easy
789 Escape The Ghosts Go Medium
790 Domino and Tromino Tiling Go Medium
791 Custom Sort String Go Medium
792 Number of Matching Subsequences Go Medium
793 Preimage Size of Factorial Zeroes Function Go Hard
794 Valid Tic-Tac-Toe State Go Medium
795 Number of Subarrays with Bounded Maximum Go Medium
796 Rotate String Go Easy
797 All Paths From Source to Target Go Medium
798 Smallest Rotation with Highest Score Go Hard
799 Champagne Tower Go Medium
800 Similar RGB Color 🔒 Go Easy
801 Minimum Swaps To Make Sequences Increasing Go Medium
802 Find Eventual Safe States Go Medium
803 Bricks Falling When Hit Go Hard
804 Unique Morse Code Words Go Easy
805 Split Array With Same Average Go Hard
806 Number of Lines To Write String Go Easy
807 Max Increase to Keep City Skyline Go Medium
808 Soup Servings Go Medium
809 Expressive Words Go Medium
810 Chalkboard XOR Game Go Hard
811 Subdomain Visit Count Go Easy
812 Largest Triangle Area Go Easy
813 Largest Sum of Averages Go Medium
814 Binary Tree Pruning Go Medium
815 Bus Routes Go Hard
816 Ambiguous Coordinates Go Medium
817 Linked List Components Go Medium
818 Race Car Go Hard
819 Most Common Word Go Easy
820 Short Encoding of Words Go Medium
821 Shortest Distance to a Character Go Easy
822 Card Flipping Game Go Medium
823 Binary Trees With Factors Go Medium
824 Goat Latin Go Easy
825 Friends Of Appropriate Ages Go Medium
826 Most Profit Assigning Work Go Medium
827 Making A Large Island Go Hard
828 Unique Letter String Go Hard
829 Consecutive Numbers Sum Go Hard
830 Positions of Large Groups Go Easy
831 Masking Personal Information Go Medium
832 Flipping an Image Go Easy
833 Find And Replace in String Go Medium
834 Sum of Distances in Tree Go Hard
835 Image Overlap Go Medium
836 Rectangle Overlap Go Easy
837 New 21 Game Go Medium
838 Push Dominoes Go Medium
839 Similar String Groups Go Hard
840 Magic Squares In Grid Go Easy
841 Keys and Rooms Go Medium
842 Split Array into Fibonacci Sequence Go Medium
843 Guess the Word Go Hard
844 Backspace String Compare Go Easy
845 Longest Mountain in Array Go Medium
846 Hand of Straights Go Medium
847 Shortest Path Visiting All Nodes Go Hard
848 Shifting Letters Go Medium
849 Maximize Distance to Closest Person Go Easy
850 Rectangle Area II Go Hard
851 Loud and Rich Go Medium
852 Peak Index in a Mountain Array Go Easy
853 Car Fleet Go Medium
854 K-Similar Strings Go Hard
855 Exam Room Go Medium
856 Score of Parentheses Go Medium
857 Minimum Cost to Hire K Workers Go Hard
858 Mirror Reflection Go Medium
859 Buddy Strings Go Easy
860 Lemonade Change Go Easy
861 Score After Flipping Matrix Go Medium
862 Shortest Subarray with Sum at Least K Go Hard
863 All Nodes Distance K in Binary Tree Go Medium
864 Shortest Path to Get All Keys Go Hard
865 Smallest Subtree with all the Deepest Nodes Go Medium
866 Prime Palindrome Go Medium
867 Transpose Matrix Go Easy
868 Binary Gap Go Easy
869 Reordered Power of 2 Go Medium
870 Advantage Shuffle Go Medium
871 Minimum Number of Refueling Stops Go Hard
872 Leaf-Similar Trees Go Easy
873 Length of Longest Fibonacci Subsequence Go Medium
874 Walking Robot Simulation Go Easy
875 Koko Eating Bananas Go Medium
876 Middle of the Linked List Go Easy
877 Stone Game Go Medium
878 Nth Magical Number Go Hard
879 Profitable Schemes Go Hard
880 Decoded String at Index Go Medium
881 Boats to Save People Go Medium
882 Reachable Nodes In Subdivided Graph Go Hard
883 Projection Area of 3D Shapes Go Easy
884 Uncommon Words from Two Sentences Go Easy
885 Spiral Matrix III Go Medium
886 Possible Bipartition Go Medium
887 Super Egg Drop Go Hard
888 Fair Candy Swap Go Easy
889 Construct Binary Tree from Preorder and Postorder Traversal Go Medium
890 Find and Replace Pattern Go Medium
891 Sum of Subsequence Widths Go Hard
892 Surface Area of 3D Shapes Go Easy
893 Groups of Special-Equivalent Strings Go Easy
894 All Possible Full Binary Trees Go Medium
895 Maximum Frequency Stack Go Hard
896 Monotonic Array Go Easy
897 Increasing Order Search Tree Go Easy
898 Bitwise ORs of Subarrays Go Medium
899 Orderly Queue Go Hard
900 RLE Iterator Go Medium
901 Online Stock Span Go Medium
902 Numbers At Most N Given Digit Set Go Hard
903 Valid Permutations for DI Sequence Go Hard
904 Fruit Into Baskets Go Medium
905 Sort Array By Parity Go Easy
906 Super Palindromes Go Hard
907 Sum of Subarray Minimums Go Medium
908 Smallest Range I Go Easy
909 Snakes and Ladders Go Medium
910 Smallest Range II Go Medium
911 Online Election Go Medium
913 Cat and Mouse Go Hard
914 X of a Kind in a Deck of Cards Go Easy
915 Partition Array into Disjoint Intervals Go Medium
916 Word Subsets Go Medium
917 Reverse Only Letters Go Easy
918 Maximum Sum Circular Subarray Go Medium
919 Complete Binary Tree Inserter Go Medium
920 Number of Music Playlists Go Hard
921 Minimum Add to Make Parentheses Valid Go Medium
922 Sort Array By Parity II Go Easy
923 3Sum With Multiplicity Go Medium
924 Minimize Malware Spread Go Hard
925 Long Pressed Name Go Easy
926 Flip String to Monotone Increasing Go Medium
927 Three Equal Parts Go Hard
928 Minimize Malware Spread II Go Hard
929 Unique Email Addresses Go Easy
930 Binary Subarrays With Sum Go Medium
931 Minimum Falling Path Sum Go Medium
932 Beautiful Array Go Medium
933 Number of Recent Calls Go Easy
934 Shortest Bridge Go Medium
935 Knight Dialer Go Medium
936 Stamping The Sequence Go Hard
937 Reorder Log Files Go Easy
938 Range Sum of BST Go Medium
939 Minimum Area Rectangle Go Medium
940 Distinct Subsequences II Go Hard
941 Valid Mountain Array Go Easy
942 DI String Match Go Easy
943 Find the Shortest Superstring Go Hard
944 Delete Columns to Make Sorted Go Easy
945 Minimum Increment to Make Array Unique Go Medium
946 Validate Stack Sequences Go Medium
947 Most Stones Removed with Same Row or Column Go Medium
948 Bag of Tokens Go Medium
949 Largest Time for Given Digits Go Easy
950 Reveal Cards In Increasing Order Go Medium
951 Flip Equivalent Binary Trees Go Medium
952 Largest Component Size by Common Factor Go Hard
953 Verifying an Alien Dictionary Go Easy
954 Array of Doubled Pairs Go Medium
955 Delete Columns to Make Sorted II Go Medium
956 Tallest Billboard Go Hard
957 Prison Cells After N Days Go Medium
958 Check Completeness of a Binary Tree Go Medium
959 Regions Cut By Slashes Go Medium
960 Delete Columns to Make Sorted III Go Hard
961 N-Repeated Element in Size 2N Array Go Easy
962 Maximum Width Ramp Go Medium
963 Minimum Area Rectangle II Go Medium
964 Least Operators to Express Number Go Hard
Go

Learning by doing!

讨论数量: 0
(= ̄ω ̄=)··· 暂无内容!

  • 请注意单词拼写,以及中英文排版,参考此页
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`, 更多语法请见这里 Markdown 语法
  • 支持表情,使用方法请见 Emoji 自动补全来咯,可用的 Emoji 请见 :metal: :point_right: Emoji 列表 :star: :sparkles:
  • 上传图片, 支持拖拽和剪切板黏贴上传, 格式限制 - jpg, png, gif
  • 发布框支持本地存储功能,会在内容变更时保存,「提交」按钮点击时清空
  请勿发布不友善或者负能量的内容。与人为善,比聪明更重要!