Skip to content

nipunn-git/LeetCode-Solutions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

328 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LeetCode-Solutions

LeetCode Topics

Array

Problem Name Difficulty
0001-two-sum Easy
0011-container-with-most-water Medium
0026-remove-duplicates-from-sorted-array Easy
0034-find-first-and-last-position-of-element-in-sorted-array Medium
0035-search-insert-position Easy
0041-first-missing-positive Hard
0048-rotate-image Medium
0051-n-queens Hard
0055-jump-game Medium
0066-plus-one Easy
0073-set-matrix-zeroes Medium
0118-pascals-triangle Easy
0152-maximum-product-subarray Medium
0217-contains-duplicate Easy
0260-single-number-iii Medium
0268-missing-number Easy
0283-move-zeroes Easy
0455-assign-cookies Easy
0485-max-consecutive-ones Easy
0810-chalkboard-xor-game Hard
1288-remove-covered-intervals Medium
1365-how-many-numbers-are-smaller-than-the-current-number Easy
1512-number-of-good-pairs Easy
1672-richest-customer-wealth Easy
1732-find-the-highest-altitude Easy
1833-maximum-ice-cream-bars Medium
1846-maximum-element-after-decreasing-and-rearranging Medium
1929-concatenation-of-array Easy
1979-find-greatest-common-divisor-of-array Easy
2535-difference-between-element-sum-and-digit-sum-of-an-array Easy
2574-left-and-right-sum-differences Easy
2942-find-words-containing-character Easy
3190-find-minimum-operations-to-make-all-elements-divisible-by-three Easy
3300-minimum-element-after-replacement-with-digit-sum Easy
3432-count-partitions-with-even-sum-difference Easy
3512-minimum-operations-to-make-array-sum-divisible-by-k Easy
3668-restore-finishing-order Easy
3701-compute-alternating-sum Easy
3925-concatenate-array-with-reverse Easy

Hash Table

Problem Name Difficulty
0001-two-sum Easy
0003-longest-substring-without-repeating-characters Medium
0012-integer-to-roman Medium
0013-roman-to-integer Easy
0041-first-missing-positive Hard
0073-set-matrix-zeroes Medium
0202-happy-number Easy
0217-contains-duplicate Easy
0268-missing-number Easy
1189-maximum-number-of-balloons Easy
1358-number-of-substrings-containing-all-three-characters Medium
1365-how-many-numbers-are-smaller-than-the-current-number Easy
1512-number-of-good-pairs Easy
3668-restore-finishing-order Easy
3760-maximum-substrings-with-distinct-start Medium

Math

Problem Name Difficulty
0009-palindrome-number Easy
0012-integer-to-roman Medium
0013-roman-to-integer Easy
0029-divide-two-integers Medium
0048-rotate-image Medium
0050-powx-n Medium
0066-plus-one Easy
0069-sqrtx Easy
0070-climbing-stairs Easy
0171-excel-sheet-column-number Easy
0202-happy-number Easy
0231-power-of-two Easy
0258-add-digits Easy
0263-ugly-number Easy
0268-missing-number Easy
0292-nim-game Easy
0342-power-of-four Easy
0367-valid-perfect-square Easy
0507-perfect-number Easy
0509-fibonacci-number Easy
0810-chalkboard-xor-game Hard
1281-subtract-the-product-and-sum-of-digits-of-an-integer Easy
1342-number-of-steps-to-reduce-a-number-to-zero Easy
1512-number-of-good-pairs Easy
1688-count-of-matches-in-tournament Easy
1979-find-greatest-common-divisor-of-array Easy
2235-add-two-integers Easy
2413-smallest-even-multiple Easy
2427-number-of-common-factors Easy
2469-convert-the-temperature Easy
2520-count-the-digits-that-divide-a-number Easy
2535-difference-between-element-sum-and-digit-sum-of-an-array Easy
2652-sum-multiples Easy
2769-find-the-maximum-achievable-number Easy
2894-divisible-and-non-divisible-sums-difference Easy
3099-harshad-number Easy
3190-find-minimum-operations-to-make-all-elements-divisible-by-three Easy
3300-minimum-element-after-replacement-with-digit-sum Easy
3432-count-partitions-with-even-sum-difference Easy
3512-minimum-operations-to-make-array-sum-divisible-by-k Easy
3516-find-closest-person Easy
3658-gcd-of-odd-and-even-sums Easy
3751-total-waviness-of-numbers-in-range-i Medium
3754-concatenate-non-zero-digits-and-multiply-by-sum-i Easy
3783-mirror-distance-of-an-integer Easy

String

Problem Name Difficulty
0003-longest-substring-without-repeating-characters Medium
0012-integer-to-roman Medium
0013-roman-to-integer Easy
0020-valid-parentheses Easy
0022-generate-parentheses Medium
0028-find-the-index-of-the-first-occurrence-in-a-string Easy
0058-length-of-last-word Easy
0125-valid-palindrome Easy
0171-excel-sheet-column-number Easy
0344-reverse-string Easy
0520-detect-capital Easy
1189-maximum-number-of-balloons Easy
1358-number-of-substrings-containing-all-three-characters Medium
2942-find-words-containing-character Easy
3760-maximum-substrings-with-distinct-start Medium

Linked List

Problem Name Difficulty
0024-swap-nodes-in-pairs Medium

Recursion

Problem Name Difficulty
0024-swap-nodes-in-pairs Medium
0050-powx-n Medium
0231-power-of-two Easy
0342-power-of-four Easy
0509-fibonacci-number Easy

Sorting

Problem Name Difficulty
0217-contains-duplicate Easy
0268-missing-number Easy
0455-assign-cookies Easy
1288-remove-covered-intervals Medium
1365-how-many-numbers-are-smaller-than-the-current-number Easy
1833-maximum-ice-cream-bars Medium
1846-maximum-element-after-decreasing-and-rearranging Medium

Counting Sort

Problem Name Difficulty
1189-maximum-number-of-balloons Easy
1365-how-many-numbers-are-smaller-than-the-current-number Easy
1512-number-of-good-pairs Easy
1833-maximum-ice-cream-bars Medium

Enumeration

Problem Name Difficulty
2427-number-of-common-factors Easy
3751-total-waviness-of-numbers-in-range-i Medium

Number Theory

Problem Name Difficulty
0258-add-digits Easy
1979-find-greatest-common-divisor-of-array Easy
2413-smallest-even-multiple Easy
2427-number-of-common-factors Easy
3658-gcd-of-odd-and-even-sums Easy

Binary Search

Problem Name Difficulty
0034-find-first-and-last-position-of-element-in-sorted-array Medium
0035-search-insert-position Easy
0069-sqrtx Easy
0268-missing-number Easy
0367-valid-perfect-square Easy

Stack

Problem Name Difficulty
0020-valid-parentheses Easy

Two Pointers

Problem Name Difficulty
0011-container-with-most-water Medium
0026-remove-duplicates-from-sorted-array Easy
0028-find-the-index-of-the-first-occurrence-in-a-string Easy
0125-valid-palindrome Easy
0202-happy-number Easy
0283-move-zeroes Easy
0344-reverse-string Easy
0455-assign-cookies Easy

String Matching

Problem Name Difficulty
0028-find-the-index-of-the-first-occurrence-in-a-string Easy

Simulation

Problem Name Difficulty
0258-add-digits Easy
1688-count-of-matches-in-tournament Easy
1929-concatenation-of-array Easy
3701-compute-alternating-sum Easy
3925-concatenate-array-with-reverse Easy

Dynamic Programming

Problem Name Difficulty
0022-generate-parentheses Medium
0055-jump-game Medium
0070-climbing-stairs Easy
0118-pascals-triangle Easy
0152-maximum-product-subarray Medium
0509-fibonacci-number Easy
3751-total-waviness-of-numbers-in-range-i Medium

Memoization

Problem Name Difficulty
0070-climbing-stairs Easy
0509-fibonacci-number Easy

Bit Manipulation

Problem Name Difficulty
0029-divide-two-integers Medium
0231-power-of-two Easy
0260-single-number-iii Medium
0268-missing-number Easy
0342-power-of-four Easy
0476-number-complement Easy
0810-chalkboard-xor-game Hard
1342-number-of-steps-to-reduce-a-number-to-zero Easy

Matrix

Problem Name Difficulty
0048-rotate-image Medium
0073-set-matrix-zeroes Medium
1672-richest-customer-wealth Easy

Prefix Sum

Problem Name Difficulty
1732-find-the-highest-altitude Easy
2574-left-and-right-sum-differences Easy
3432-count-partitions-with-even-sum-difference Easy

Greedy

Problem Name Difficulty
0011-container-with-most-water Medium
0055-jump-game Medium
0455-assign-cookies Easy
1833-maximum-ice-cream-bars Medium
1846-maximum-element-after-decreasing-and-rearranging Medium

Backtracking

Problem Name Difficulty
0022-generate-parentheses Medium
0051-n-queens Hard

Database

Problem Name Difficulty
0175-combine-two-tables Easy
0177-nth-highest-salary Medium
0178-rank-scores Medium
0181-employees-earning-more-than-their-managers Easy
0183-customers-who-never-order Easy
0627-swap-sex-of-employees Easy

Sliding Window

Problem Name Difficulty
0003-longest-substring-without-repeating-characters Medium
1358-number-of-substrings-containing-all-three-characters Medium

Brainteaser

Problem Name Difficulty
0292-nim-game Easy
0810-chalkboard-xor-game Hard

Game Theory

Problem Name Difficulty
0292-nim-game Easy
0810-chalkboard-xor-game Hard

About

This repository provides all my solutions of the Leetcode questions which I have solved.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors