Skip to content

A place where I upload all the solutions to Leetcode problems I have solved

Notifications You must be signed in to change notification settings

KennyMcGeoch/LeetCodeExercises

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeetCodeExercises

Coding exercises. Exercises will be named in format Problem Number (Difficulty) e.g. 13. Roman to Integer (Easy) is named 0013E. Also note that preview of Markdown file will renumber files

Full List of Completed Projects in Numerical Order:

  1. Two Sum (Easy)
  2. Add Two Numbers (Medium)
  3. Longest Substring Without Repeating Characters (Medium)
  4. Median of Two Sorted Arrays (Hard)
  5. Longest Palindromic Substring (Medium)
  6. Reverse Integer (Medium)
  7. String to Integer (atoi) (Medium)
  8. Palindrome Number (Easy)
  9. Container With Most Water (Medium)
  10. Integer to Roman (Medium)
  11. Roman to Integer (Easy)
  12. Longest Common Prefix (Easy)
  13. 3Sum Closest (Medium)
  14. Letter Combinations of a Phone Number (Medium)
  15. Remove Nth Node From End of List (Medium)
  16. Valid Parentheses (Easy)
  17. Merge Two Sorted Lists (Easy)
  18. Merge k Sorted Lists (Hard)
  19. Remove Duplicates from Sorted Array (Easy)
  20. Remove Element (Easy)
  21. Find the Index of the First Occurrence in a String (Medium)
  22. Divide Two Integers (Medium)
  23. Search in Rotated Sorted Array (Medium)
  24. Find First and Last Position of Element in Sorted Array (Medium)
  25. Search Insert Position (Easy)
  26. Valid Sudoku (Medium)
  27. Sudoku Solver (Hard)
  28. Count and Say (Medium)
  29. Combination Sum (Medium)
  30. Combination Sum II (Medium)
  31. First Missing Positive (Hard)
  32. Trapping Rain Water (Hard)
  33. Jump Game II (Medium)
  34. Permutations (Medium)
  35. Rotate Image (Medium)
  36. Group Anagrams (Medium)
  37. Pow(x, n) (Medium)
  38. Maximum Subarray (Medium)
  39. Spiral Matrix (Medium)
  40. Jump Game (Medium)
  41. Merge Intervals (Medium)
  42. Insert Interval (Medium)
  43. Length of Last Word (Easy)
  44. Spiral Matrix II (Medium)
  45. Rotate List (Medium)
  46. Unique Paths (Medium)
  47. Unique Paths II (Medium)
  48. Plus One (Easy)
  49. Sqrt(x) (Easy)
  50. Climbing Stairs (Easy)
  51. Set Matrix Zeroes (Medium)
  52. Search a 2D Matrix (Medium)
  53. Sort Colors (Medium)
  54. Minimum Window Substring (Hard)
  55. Subsets (Medium)
  56. Word Search (Medium)
  57. Remove Duplicates from Sorted Array II (Medium)
  58. Search in Rotated Sorted Array II (Medium)
  59. Remove Duplicates from Sorted List II (Medium)
  60. Remove Duplicates from Sorted List (Easy)
  61. Merge Sorted Array (Easy)
  62. Decode Ways (Medium)
  63. Reverse Linked List II (Medium)
  64. Binary Tree Inorder Traversal (Easy)
  65. Validate Binary Search Tree (Medium)
  66. Same Tree (Easy)
  67. Symmetric Tree (Easy)
  68. Binary Tree Level Order Traversal (Medium)
  69. Maximum Depth of Binary Tree (Easy)
  70. Convert Sorted Array to Binary Search Tree (Easy)
  71. Balanced Binary Tree (Easy)
  72. Minimum Depth of Binary Tree (Easy)
  73. Path Sum (Easy)
  74. Path Sum II (Medium)
  75. Pascal's Triangle (Easy)
  76. Pascal's Triangle II (Easy)
  77. Triangle (Medium)
  78. Best Time to Buy and Sell Stock (Easy)
  79. Valid Palindrome (Easy)
  80. Sum Root to Leaf Numbers (Medium)
  81. Palindrome Partitioning (Medium)
  82. Single Number (Easy)
  83. Single Number II (Medium)
  84. Word Break II (Hard)
  85. Linked List Cycle (Easy)
  86. Linked List Cycle II (Medium)
  87. Reorder List (Medium)
  88. Binary Tree Preorder Traversal (Easy)
  89. Binary Tree Postorder Traversal (Easy)
  90. Sort List (Medium)
  91. Evaluate Reverse Polish Notation (Medium)
  92. Reverse Words in a String (Medium)
  93. Maximum Product Subarray (Medium)
  94. Find Minimum in Rotated Sorted Array (Medium)
  95. Intersection of Two Linked Lists (Easy)
  96. Find Peak Element (Medium)
  97. Compare Version Numbers (Medium)
  98. Two Sum II - Input Array Is Sorted (Medium)
  99. Excel Sheet Column Title (Easy)
  100. Majority Element (Easy)
  101. Excel Sheet Column Number (Easy)
  102. Combine Two Tables (Easy)
  103. Second Highest Salary (Medium)
  104. Largest Number (Medium)
  105. Consecutive Numbers (Medium)
  106. Employees Earning More Than Their Managers (Easy)
  107. Duplicate Emails (Easy)
  108. Customers Who Never Order (Easy)
  109. Department Highest Salary (Medium)
  110. Rotate Array (Medium)
  111. Number of 1 Bits (Easy)
  112. Delete Duplicate Emails (Easy)
  113. Rising Temperature (Easy)
  114. House Robber (Medium)
  115. Binary Tree Right Side View (Medium)
  116. Number of Islands (Medium)
  117. Bitwise AND of Numbers Range (Medium)
  118. Happy Number (Easy)
  119. Remove Linked List Elements (Easy)
  120. Count Primes (Medium)
  121. Isomorphic Strings (Easy)
  122. Reverse Linked List (Easy)
  123. Minimum Size Subarray Sum (Medium)
  124. Course Schedule II (Medium)
  125. Word Search II (Hard)
  126. Shortest Palindrome (Hard)
  127. Kth Largest Element in an Array (Medium)
  128. Contains Duplicate (Easy)
  129. Contains Duplicate II (Easy)
  130. Count Complete Tree Nodes (Medium)
  131. Rectangle Area (Medium)
  132. Implement Stack using Queues (Easy)
  133. Invert Binary Tree (Easy)
  134. Summary Ranges (Easy)
  135. Majority Element II (Medium)
  136. Kth Smallest Element in a BST (Medium)
  137. Power of Two (Easy)
  138. Implement Queue using Stacks (Easy)
  139. Number of Digit One (Hard)
  140. Palindrome Linked List (Easy)
  141. Lowest Common Ancestor of a Binary Search Tree (Medium)
  142. Lowest Common Ancestor of a Binary Tree (Medium)
  143. Delete Node in a Linked List (Medium)
  144. Product of Array Except Self (Medium)
  145. Valid Anagram (Easy)
  146. Binary Tree Paths (Easy)
  147. Add Digits (Easy)
  148. Single Number III (Medium)
  149. Ugly Number (Easy)
  150. Ugly Number II (Medium)
  151. Missing Number (Easy)
  152. Integer to English Words (Hard)
  153. H-Index (Medium)
  154. H-Index II (Medium)
  155. First Bad Version (Easy)
  156. Perfect Squares (Medium)
  157. Move Zeroes (Easy)
  158. Find the Duplicate Number (Medium)
  159. Game of Life (Medium)
  160. Word Pattern (Easy)
  161. Nim Game (Easy)
  162. Bulls and Cows (Medium)
  163. Longest Increasing Subsequence (Medium)
  164. Range Sum Query - Immutable (Easy)
  165. Bulb Switcher (Medium)
  166. Coin Change (Medium)
  167. Power of Three (Easy)
  168. Odd Even Linked List (Medium)
  169. Increasing Triplet Subsequence (Medium)
  170. Palindrome Pairs (Hard)
  171. Counting Bits (Easy)
  172. Flatten Nested List Iterator (Medium)
  173. Power of Four (Easy)
  174. Integer Break (Medium)
  175. Reverse String (Easy)
  176. Reverse Vowels of a String (Easy)
  177. Top K Frequent Elements (Medium)
  178. Intersection of Two Arrays (Easy)
  179. Intersection of Two Arrays II (Easy)
  180. Count Numbers with Unique Digits (Medium)
  181. Valid Perfect Square (Easy)
  182. Largest Divisible Subset (Medium)
  183. Guess Number Higher or Lower (Easy)
  184. Insert Delete GetRandom O(1) (Medium)
  185. Ransom Note (Easy)
  186. First Unique Character in a String (Easy)
  187. Find the Difference (Easy)
  188. Is Subsequence (Easy)
  189. Decode String (Medium)
  190. Remove K Digits (Medium)
  191. Sum of Left Leaves (Easy)
  192. Longest Palindrome (Easy)
  193. Fizz Buzz (Easy)
  194. Arithmetic Slices (Medium)
  195. Third Maximum Number (Easy)
  196. Pacific Atlantic Water Flow (Medium)
  197. Battleships in a Board (Medium)
  198. Longest Repeating Character Replacement (Medium)
  199. Minimum Genetic Mutation (Medium)
  200. Number of Segments in a String (Easy)
  201. Path Sum III (Medium)
  202. Find All Anagrams in a String (Medium)
  203. Arranging Coins (Easy)
  204. Find All Duplicates in an Array (Medium)
  205. Add Two Numbers II (Medium)
  206. Find All Numbers Disappeared in an Array (Easy)
  207. Sort Characters By Frequency (Medium)
  208. Minimum Number of Arrows to Burst Balloons (Medium)
  209. Assign Cookies (Easy)
  210. Poor Pigs (Hard)
  211. Island Perimeter (Easy)
  212. Number Complement (Easy)
  213. Max Consecutive Ones (Easy)
  214. Construct the Rectangle (Easy)
  215. Target Sum (Medium)
  216. Teemo Attacking (Easy)
  217. Next Greater Element I (Easy)
  218. Keyboard Row (Easy)
  219. Find Mode in Binary Search Tree (Easy)
  220. Relative Ranks (Easy)
  221. Perfect Number (Easy)
  222. Fibonacci Number (Easy)
  223. Find Bottom Left Tree Value (Medium)
  224. Freedom Trail (Hard)
  225. Find Largest Value in Each Tree Row (Medium)
  226. Detect Capital (Easy)
  227. Continuous Subarray Sum (Medium)
  228. Contiguous Array (Medium)
  229. Minimum Absolute Difference in BST (Easy)
  230. Minimum Time Difference (Medium)
  231. Reverse String II (Easy)
  232. Diameter of Binary Tree (Easy)
  233. Number of Provinces (Medium)
  234. Reverse Words in a String III (Easy)
  235. Reshape the Matrix (Easy)
  236. Permutation in String (Medium)
  237. Managers with at Least 5 Direct Reports (Medium)
  238. Distribute Candies (Easy)
  239. Employee Bonus (Easy)
  240. Find Customer Referee (Easy)
  241. Investments in 2016 (Medium)
  242. Customer Placing the Largest Number of Orders (Easy)
  243. N-ary Tree Preorder Traversal (Easy)
  244. Big Countries (Easy)
  245. Classes More Than 5 Students (Easy)
  246. Friend Requests II: Who Has the Most Friends (Medium)
  247. Can Place Flowers (Easy)
  248. Construct String from Binary Tree (Easy)
  249. Triangle Judgement (Easy)
  250. Biggest Single Number (Easy)
  251. Not Boring Movies (Easy)
  252. Task Scheduler (Medium)
  253. Add One Row to Tree (Medium)
  254. Maximum Distance in Arrays (Medium)
  255. Exchange Seats (Medium)
  256. Swap Salary (Easy)
  257. Smallest Range Covering Elements from K Lists (Hard)
  258. Sum of Square Numbers (Medium)
  259. Design Circular Deque (Medium)
  260. Set Mismatch (Easy)
  261. Palindromic Substrings (Medium)
  262. Replace Words (Medium)
  263. Dota2 Senate (Medium)
  264. 2 Keys Keyboard (Medium)
  265. Two Sum IV - Input is a BST (Easy)
  266. Image Smoother (Easy)
  267. Maximum Swap (Medium)
  268. Longest Continuous Increasing Subsequence (Easy)
  269. Valid Parenthesis String (Medium)
  270. Valid Palindrome II (Easy)
  271. Top K Frequent Words (Medium)
  272. Max Area of Island (Medium)
  273. Degree of an Array (Easy)
  274. Search in a Binary Search Tree (Easy)
  275. Insert into a Binary Search Tree (Medium)
  276. Kth Largest Element in a Stream (Easy)
  277. Binary Search (Easy)
  278. Design HashSet (Easy)
  279. Design HashMap (Easy)
  280. To Lower Case (Easy)
  281. Subarray Product Less Than K (Medium)
  282. Find K-th Smallest Pair Distance (Hard)
  283. Find Pivot Index (Easy)
  284. Split Linked List in Parts (Medium)
  285. Number of Atoms (Hard)
  286. Flood Fill (Easy)
  287. Asteroid Collision (Medium)
  288. Daily Temperatures (Medium)
  289. Find Smallest Letter Greater Than Target (Easy)
  290. Min Cost Climbing Stairs (Easy)
  291. Largest Number At Least Twice of Others (Easy)
  292. Open the Lock (Medium)
  293. Toeplitz Matrix (Easy)
  294. Max Chunks To Make Sorted (Medium)
  295. Cheapest Flights Within K Stops (Medium)
  296. Minimum Distance Between BST Nodes (Easy)
  297. Rotate String (Easy)
  298. K-th Symbol in Grammar (Medium)
  299. Custom Sort String (Medium)
  300. Bus Routes (Hard)
  301. Most Profit Assigning Work (Medium)
  302. Image Overlap (Medium)
  303. Rectangle Overlap (Easy)
  304. Magic Squares In Grid (Medium)
  305. Backspace String Compare (Easy)
  306. Hand of Straights (Medium)
  307. Peak Index in a Mountain Array (Medium)
  308. Buddy Strings (Easy)
  309. Lemonade Change (Easy)
  310. Score After Flipping Matrix (Medium)
  311. Transpose Matrix (Easy)
  312. Leaf-Similar Trees (Easy)
  313. Walking Robot Simulation (Medium)
  314. Middle of the Linked List (Easy)
  315. Boats to Save People (Medium)
  316. Uncommon Words from Two Sentences (Easy)
  317. Spiral Matrix III (Medium)
  318. Orderly Queue (Hard)
  319. Sort an Array (Medium)
  320. Minimum Add to Make Parentheses Valid (Medium)
  321. Binary Subarrays With Sum (Medium)
  322. Minimum Falling Path Sum (Medium)
  323. Number of Recent Calls (Easy)
  324. Reorder Data in Log Files (Medium)
  325. Range Sum of BST (Easy)
  326. Minimum Increment to Make Array Unique (Medium)
  327. Validate Stack Sequences (Medium)
  328. Most Stones Removed with Same Row or Column (Medium)
  329. Bag of Tokens (Medium)
  330. Reveal Cards In Increasing Order (Medium)
  331. Flip Equivalent Binary Trees (Medium)
  332. Verifying an Alien Dictionary (Easy)
  333. Maximum Width Ramp (Medium)
  334. Subarray Sums Divisible by K (Medium)
  335. Largest Perimeter Triangle (Easy)
  336. Squares of a Sorted Array (Easy)
  337. Sum of Even Numbers After Queries (Medium)
  338. Smallest String Starting From Leaf (Medium)
  339. Rotting Oranges (Medium)
  340. Find the Town Judge (Easy)
  341. Find Common Characters (Easy)
  342. Complement of Base 10 Integer (Easy)
  343. Best Sightseeing Pair (Medium)
  344. Maximum Difference Between Node and Ancestor (Medium)
  345. Binary Search Tree to Greater Sum Tree (Medium)
  346. Partition Array for Maximum Sum (Medium)
  347. Customers Who Bought All Products (Medium)
  348. Last Stone Weight (Easy)
  349. Remove All Adjacent Duplicates In String (Easy)
  350. Actors and Directors Who Cooperated At Least Three Times (Easy)
  351. Height Checker (Easy)
  352. Grumpy Bookstore Owner (Medium)
  353. Product Sales Analysis I (Easy)
  354. Product Sales Analysis III (Medium)
  355. Flip Columns For Maximum Number of Equal Rows (Medium)
  356. Project Employees I (Easy)
  357. Occurrences After Bigram (Easy)
  358. Duplicate Zeros (Easy)
  359. Find in Mountain Array (Hard)
  360. Delete Nodes And Return Forest (Medium)
  361. Relative Sort Array (Easy)
  362. N-th Tribonacci Number (Easy)
  363. User Activity for the Past 30 Days I (Easy)
  364. Longest Common Subsequence (Medium)
  365. Article Views I (Easy)
  366. Day of the Year (Easy)
  367. Find Words That Can Be Formed by Characters (Easy)
  368. Maximum Level Sum of a Binary Tree (Medium)
  369. Product Price at a Given Date (Medium)
  370. Remove Zero Sum Consecutive Nodes from Linked List (Medium)
  371. Immediate Food Delivery II (Medium)
  372. Reverse Substrings Between Each Pair of Parentheses (Medium)
  373. Monthly Transactions I (Medium)
  374. Last Person to Fit in the Bus (Medium)
  375. Unique Number of Occurrences (Easy)
  376. Get Equal Substrings Within Budget (Medium)
  377. Remove All Adjacent Duplicates in String II (Medium)
  378. Queries Quality and Percentage (Easy)
  379. Count Vowels Permutation (Hard)
  380. Split a String in Balanced Strings (Easy)
  381. Airplane Seat Assignment Probability (Medium)
  382. Check If It Is a Straight Line (Easy)
  383. Remove Sub-Folders from the Filesystem (Medium)
  384. Count Number of Nice Subarrays (Medium)
  385. Minimum Remove to Make Valid Parentheses (Medium)
  386. Average Selling Price (Easy)
  387. Maximum Score Words Formed by Letters (Hard)
  388. Minimum Time Visiting All Points (Easy)
  389. Students and Examinations (Easy)
  390. Subtract the Product and Sum of Digits of an Integer (Easy)
  391. Group the People Given the Group Size They Belong To (Medium)
  392. Element Appearing More Than 25% In Sorted Array (Easy)
  393. Minimum Falling Path Sum II (Hard)
  394. Convert Binary Number in a Linked List to Integer (Easy)
  395. Sequential Digits (Medium)
  396. Shortest Path in a Grid with Obstacles Elimination (Hard)
  397. Jump Game III (Medium)
  398. Decrypt String from Alphabet to Integer Mapping (Easy)
  399. XOR Queries of a Subarray (Medium)
  400. Maximum 69 Number (Easy)
  401. Delete Leaves With a Given Value (Medium)
  402. List the Products Ordered in a Period (Easy)
  403. Rank Transform of an Array (Easy)
  404. The K Weakest Rows in a Matrix (Easy)
  405. Movie Rating (Medium)
  406. Number of Steps to Reduce a Number to Zero (Easy)
  407. Check If N and Its Double Exist (Easy)
  408. Minimum Number of Steps to Make Two Strings Anagram (Medium)
  409. Count Negative Numbers in a Sorted Matrix (Easy)
  410. Sort Integers by The Number of 1 Bits (Easy)
  411. How Many Numbers Are Smaller Than the Current Number (Easy)
  412. Linked List in Binary Tree (Medium)
  413. Find the Longest Substring Containing Vowels in Even Counts (Medium)
  414. Replace Employee ID With The Unique Identifier (Easy)
  415. Lucky Numbers in a Matrix (Easy)
  416. Design a Stack With Increment Operation (Medium)
  417. Find the Distance Value Between Two Arrays (Easy)
  418. Count Number of Teams (Medium)
  419. Minimum Subsequence in Non-Increasing Order (Easy)
  420. Number of Steps to Reduce a Number in Binary Representation to One (Medium)
  421. Longest Happy String (Medium)
  422. Maximum Score After Splitting a String (Easy)
  423. Destination City (Easy)
  424. Build an Array With Stack Operations (Medium)
  425. Consecutive Characters (Easy)
  426. Maximum Number of Vowels in a Substring of Given Length (Medium)
  427. Pseudo-Palindromic Paths in a Binary Tree (Medium)
  428. Make Two Arrays Equal by Reversing Subarrays (Easy)
  429. Maximum Product of Two Elements in an Array (Easy)
  430. Final Prices With a Special Discount in a Shop (Easy)
  431. Running Sum of 1d Array (Easy)
  432. Least Number of Unique Integers after K Removals (Medium)
  433. Group Sold Products By The Date (Easy)
  434. Average Salary Excluding the Minimum and Maximum Salary (Easy)
  435. Longest Subarray of 1's After Deleting One Element (Medium)
  436. Path Crossing (Easy)
  437. Check If Array Pairs Are Divisible by k (Medium)
  438. Can Make Arithmetic Progression From Sequence (Easy)
  439. Last Moment Before All Ants Fall Out of a Plank (Medium)
  440. Range Sum of Sorted Subarray Sums (Medium)
  441. Minimum Difference Between Largest and Smallest Value in Three Moves (Medium)
  442. Number of Good Pairs (Easy)
  443. Number of Substrings With Only 1s (Medium)
  444. Water Bottles (Easy)
  445. Count Odd Numbers in an Interval Range (Easy)
  446. Patients With a Condition (Easy)
  447. Shuffle String (Easy)
  448. Find the Winner of an Array Game (Medium)
  449. Kth Missing Positive Number (Easy)
  450. Make The String Great (Easy)
  451. Find Kth Bit in Nth Binary String (Medium)
  452. Three Consecutive Odds (Easy)
  453. Thousand Separator (Easy)
  454. Maximum Number of Coins You Can Get (Medium)
  455. Detect Pattern of Length M Repeated K or More Times (Easy)
  456. Minimum Number of Days to Disconnect Island (Hard)
  457. Matrix Diagonal Sum (Easy)
  458. Shortest Subarray to be Removed to Make Array Sorted (Medium)
  459. Minimum Time to Make Rope Colorful (Medium)
  460. Remove Max Number of Edges to Keep Graph Fully Traversable (Hard)
  461. Customer Who Visited but Did Not Make Any Transactions (Easy)
  462. Special Positions in a Binary Matrix (Easy)
  463. Sum of All Odd Length Subarrays (Easy)
  464. Crawler Log Folder (Easy)
  465. Design Parking System (Easy)
  466. Find Valid Matrix Given Row and Column Sums (Medium)
  467. Special Array With X Elements Greater Than or Equal X (Easy)
  468. Even Odd Tree (Medium)
  469. Maximum Nesting Depth of the Parentheses (Easy)
  470. Largest Substring Between Two Equal Characters (Easy)
  471. Arithmetic Subarrays (Medium)
  472. Percentage of Users Attended a Contest (Easy)
  473. Sort Array by Increasing Frequency (Easy)
  474. Widest Vertical Area Between Two Points Containing No Points (Medium)
  475. Minimum Deletions to Make Character Frequencies Unique (Medium)
  476. Defuse the Bomb (Easy)
  477. Minimum Deletions to Make String Balanced (Medium)
  478. Determine if Two Strings Are Close (Medium)
  479. Average Time of Process per Machine (Easy)
  480. Check If Two String Arrays are Equivalent (Easy)
  481. Fix Names in a Table (Easy)
  482. Merge In Between Linked Lists (Medium)
  483. Invalid Tweets (Easy)
  484. Count the Number of Consistent Strings (Easy)
  485. Sum of Absolute Differences in a Sorted Array (Medium)
  486. Count of Matches in Tournament (Easy)
  487. Richest Customer Wealth (Easy)
  488. Goal Parser Interpretation (Easy)
  489. Number of Students Unable to Eat Lunch (Easy)
  490. Average Waiting Time (Medium)
  491. Determine if String Halves Are Alike (Easy)
  492. Where Will the Ball Fall (Medium)
  493. Calculate Money in Leetcode Bank (Easy)
  494. Swapping Nodes in a Linked List (Medium)
  495. Largest Submatrix With Rearrangements (Medium)
  496. Find Followers Count (Easy)
  497. Find the Highest Altitude (Easy)
  498. Restore the Array From Adjacent Pairs (Medium)
  499. Sum of Unique Elements (Easy)
  500. Minimum Length of String After Deleting Similar Ends (Medium)
  501. Recyclable and Low Fat Products (Easy)
  502. Minimum Changes To Make Alternating Binary String (Easy)
  503. Count Number of Homogenous Substrings (Medium)
  504. Minimum Limit of Balls in a Bag (Medium)
  505. Merge Strings Alternately (Easy)
  506. The Number of Employees Which Report to Each Employee (Easy)
  507. Find Center of Star Graph (Easy)
  508. Find Nearest Point That Has the Same X or Y Coordinate (Easy)
  509. Check if Number is a Sum of Powers of Three (Medium)
  510. Primary Department for Each Employee (Easy)
  511. Check if One String Swap Can Make Strings Equal (Easy)
  512. Maximum Score of a Good Subarray (Hard)
  513. Count Nice Pairs in an Array (Medium)
  514. Sign of the Product of an Array (Easy)
  515. Find the Winner of the Circular Game (Medium)
  516. Maximum XOR for Each Query (Medium)
  517. Check if the Sentence Is Pangram (Easy)
  518. Seat Reservation Manager (Medium)
  519. Maximum Element After Decreasing and Rearranging (Medium)
  520. Maximum Distance Between a Pair of Values (Medium)
  521. Rotating the Box (Medium)
  522. Longer Contiguous Segments of Ones than Zeros (Easy)
  523. Jump Game VII (Medium)
  524. Calculate Special Bonus (Easy)
  525. Minimize Maximum Pair Sum in Array (Medium)
  526. Reduction Operations to Make the Array Elements Equal (Medium)
  527. Find the Student that Will Replace the Chalk (Medium)
  528. Redistribute Characters to Make All Strings Equal (Easy)
  529. Largest Odd Number in String (Easy)
  530. Count Sub Islands (Medium)
  531. Count Salary Categories (Medium)
  532. Maximum Product Difference Between Two Pairs (Easy)
  533. Eliminate Maximum Number of Monsters (Medium)
  534. Nearest Exit from Entrance in Maze (Medium)
  535. Concatenation of Array (Easy)
  536. Unique Length-3 Palindromic Subsequences (Medium)
  537. Confirmation Rate (Medium)
  538. Maximum Number of Points with Cost (Medium)
  539. The Number of the Smallest Unoccupied Chair (Medium)
  540. Sum of Digits of String After Convert (Easy)
  541. Largest Number After Mutating Substring (Medium)
  542. Delete Characters to Make Fancy String (Easy)
  543. Minimum Number of Swaps to Make the String Balanced (Medium)
  544. Employees With Missing Information (Easy)
  545. Find if Path Exists in Graph (Easy)
  546. Maximum Matrix Sum (Medium)
  547. Employees Whose Manager Left the Company (Easy)
  548. Find Greatest Common Divisor of Array (Easy)
  549. Find Unique Binary String (Medium)
  550. Find All Groups of Farmland (Medium)
  551. Reverse Prefix of Word (Easy)
  552. Find Original Array From Doubled Array (Medium)
  553. Minimum Number of Operations to Make Array Continuous (Hard)
  554. Grid Game (Medium)
  555. Convert 1D Array Into 2D Array (Easy)
  556. Maximize the Confusion of an Exam (Medium)
  557. Find Missing Observations (Medium)
  558. Minimum Number of Moves to Seat Everyone (Easy)
  559. Remove Colored Pieces if Both Neighbors are the Same Color (Medium)
  560. Kth Distinct String in an Array (Easy)
  561. Find the Minimum and Maximum Number of Nodes Between Critical Points (Medium)
  562. Most Beautiful Item for Each Query (Medium)
  563. Time Needed to Buy Tickets (Easy)
  564. Find Target Indices After Sorting Array (Easy)
  565. Delete the Middle Node of a Linked List (Medium)
  566. Step-By-Step Directions From a Binary Tree Node to Another (Medium)
  567. Find Subsequence of Length K With the Largest Sum (Easy)
  568. Find First Palindromic String in the Array (Easy)
  569. Adding Spaces to a String (Medium)
  570. Check if All A's Appears Before All B's (Easy)
  571. Number of Laser Beams in a Bank (Medium)
  572. Maximum Twin Sum of a Linked List (Medium)
  573. Longest Palindrome by Concatenating Two Letter Words (Medium)
  574. Minimum Swaps to Group All 1's Together II (Medium)
  575. Earliest Possible Day of Full Bloom (Hard)
  576. Number of Ways to Divide a Long Corridor (Hard)
  577. Count Elements With Strictly Smaller and Greater Elements (Easy)
  578. Rearrange Array Elements by Sign (Medium)
  579. Keep Multiplying Found Values by Two (Easy)
  580. Merge Nodes in Between Zeros (Medium)
  581. Construct String With Repeat Limit (Medium)
  582. Sort the Jumbled Numbers (Medium)
  583. Create Binary Tree From Descriptions (Medium)
  584. Divide Array Into Equal Pairs (Easy)
  585. Minimum Bit Flips to Convert Number (Easy)
  586. Find Triangular Sum of an Array (Medium)
  587. Find Players With Zero or One Losses (Medium)
  588. Add Two Integers (Easy)
  589. Root Equals Sum of Children (Easy)
  590. Calculate Digit Sum of a String (Easy)
  591. Number of Flowers in Full Bloom (Hard)
  592. Count Prefixes of a Given String (Easy)
  593. Largest 3-Same-Digit Number in String (Easy)
  594. Count Nodes Equal to Average of Subtree (Medium)
  595. Largest Combination With Bitwise AND Greater Than Zero (Medium)
  596. Maximum Total Importance of Roads (Medium)
  597. Min Max Game (Easy)
  598. Check if Matrix Is X-Matrix (Easy)
  599. Spiral Matrix IV (Medium)
  600. Evaluate Boolean Binary Tree (Easy)
  601. Move Pieces to Obtain a String (Medium)
  602. Maximum Number of Pairs in Array (Easy)
  603. Number of Zero-Filled Subarrays (Medium)
  604. Number of Unique Subjects Taught by Each Teacher (Easy)
  605. Longest Ideal Subsequence (Medium)
  606. Largest Local Values in a Matrix (Easy)
  607. Minimum Amount of Time to Collect Garbage (Medium)
  608. Meeting Rooms III (Hard)
  609. Most Frequent Even Element (Easy)
  610. Divide Intervals Into Minimum Number of Groups (Medium)
  611. Smallest Even Multiple (Easy)
  612. Reverse Odd Levels of Binary Tree (Medium)
  613. Sum of Prefix Scores of Strings (Hard)
  614. Sort the People (Easy)
  615. Longest Subarray With Maximum Bitwise AND (Medium)
  616. Number of Common Factors (Easy)
  617. Find The Original Array of Prefix Xor (Medium)
  618. Largest Positive Integer That Exists With Its Negative (Easy)
  619. Average Value of Even Numbers That Are Divisible by Three (Easy)
  620. Apply Operations to an Array (Easy)
  621. Maximum Sum of Distinct Subarrays With Length K (Medium)
  622. Number of Distinct Averages (Easy)
  623. Convert the Temperature (Easy)
  624. Minimum Number of Operations to Sort a Binary Tree by Level (Medium)
  625. Minimum Cuts to Divide a Circle (Easy)
  626. Difference Between Ones and Zeros in Row and Column (Medium)
  627. Minimum Penalty for a Shop (Medium)
  628. Find the Pivot Integer (Easy)
  629. Append Characters to String to Make Subsequence (Medium)
  630. Remove Nodes From Linked List (Medium)
  631. Circular Sentence (Easy)
  632. Divide Players Into Teams of Equal Skill (Medium)
  633. Longest Square Streak in an Array (Medium)
  634. Count Pairs Of Similar Strings (Easy)
  635. Take K of Each Character From Left and Right (Medium)
  636. Maximum Count of Positive Integer and Negative Integer (Easy)
  637. Minimum Common Value (Easy)
  638. Maximum Number of Integers to Choose From a Range I (Medium)
  639. Take Gifts From the Richest Pile (Easy)
  640. Find the Array Concatenation Value (Easy)
  641. Split With Minimum Sum (Easy)
  642. Count Total Number of Colored Cells (Medium)
  643. Pass the Pillow (Easy)
  644. Kth Largest Sum in a Binary Tree (Medium)
  645. Distribute Money to Maximum Children (Easy)
  646. Find Score of an Array After Marking All Elements (Medium)
  647. Prime Subtraction Operation (Medium)
  648. Convert an Array Into a 2D Array With Conditions (Medium)
  649. Array Prototype Last (Easy)
  650. Counter (Easy)
  651. Sleep (Easy)
  652. Snail Traversal (Medium)
  653. Flatten Deeply Nested Array (Medium)
  654. Array Reduce Transformation (Easy)
  655. JSON Deep Equal (Medium)
  656. Function Composition (Easy)
  657. Filter Elements from Array (Easy)
  658. Apply Transform Over Each Element in Array (Easy)
  659. Cousins in Binary Tree II (Medium)
  660. Generate Fibonacci Sequence (Easy)
  661. Nested Array Generator (Medium)
  662. Calculate Delayed Arrival Time (Easy)
  663. Sum Multiples (Easy)
  664. Counter II (Easy)
  665. Allow One Function Call (Easy)
  666. Create Hello World Function (Easy)
  667. Chunk Array (Easy)
  668. Number of Senior Citizens (Easy)
  669. Array Wrapper (Easy)
  670. Minimum String Length After Removing Substrings (Easy)
  671. Return Length of Arguments Passed (Easy)
  672. To Be Or Not To Be (Easy)
  673. Buy Two Chocolates (Easy)
  674. Calculator with Method Chaining (Easy)
  675. Find the Longest Semi-Repetitive Substring (Medium)
  676. Neither Minimum nor Maximum (Easy)
  677. Lexicographically Smallest String After Substring Operation (Medium)
  678. Total Distance Traveled (Easy)
  679. Robot Collisions (Hard)
  680. Sort Vowels in a String (Medium)
  681. Insert Greatest Common Divisors in Linked List (Medium)
  682. Double a Number Represented as a Linked List (Medium)
  683. Count Symmetric Integers (Easy)
  684. Determine if a Cell Is Reachable at a Given Time (Medium)
  685. Maximum Odd Binary Number (Easy)
  686. Minimum Number of Operations to Make Array Empty (Medium)
  687. Minimum Number of Changes to Make Binary String Beautiful (Medium)
  688. Find Champion II (Medium)
  689. Separate Black and White Balls (Medium)
  690. Length of Longest Subarray With at Most K Frequency (Medium)
  691. Count Subarrays Where Max Element Appears at Least K Times (Medium)
  692. Divide Array Into Arrays With Max Difference (Medium)
  693. Find Polygon With the Largest Perimeter (Medium)
  694. Find Longest Special Substring That Occurs Thrice I (Medium)
  695. Count Elements With Maximum Frequency (Easy)
  696. Minimum Number of Pushes to Type Word II (Medium)
  697. Find the Length of the Longest Common Prefix (Medium)
  698. Maximize Happiness of Selected Children (Medium)
  699. Water Bottles II (Medium)
  700. Score of a String (Easy)
  701. Minimum Array End (Medium)
  702. Special Array II (Medium)
  703. String Compression III (Medium)
  704. Delete Nodes From Linked List Present in Array (Medium)
  705. Shortest Distance After Road Addition Queries I (Medium)
  706. Find the Power of K-Size Subarrays I (Medium)
  707. Final Array State After K Multiplication Operations I (Easy)

About

A place where I upload all the solutions to Leetcode problems I have solved

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published