Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Solution to LeetCode Problems in Python and Golang 🎯

License

NotificationsYou must be signed in to change notification settings

iamsadi/LeetCode-Python-Golang

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

If you ❤️ this project, please leave me a star ⭐, and contribute to the project byforking the Repository.

About Author
  • I am Final year student from LNMIIT Jaipur
  • Looking for Job Opportunities 🏢
  • Can be reached out at, 📧 :pratulkumar1997@gmail.com

Solution to LeetCode Problems inPython

ALGORITHMS

S.No.TitleSolutionsTimeSpaceDifficultyRelated Topics
1Two SumSolution ⭐O(n)O(n)EasyArray, Hash Table
2Add Two NumbersSolutionO(n)O(1)MediumLinked List, Math
3Longest Substring Without Repeating CharactersSolution ⭐O(n)O(n)MediumHash Table, Two Pointers, String
7Reverse IntegerSolution ⭐O(n)O(1)EasyMath
9Palindrome NumberSolutionO(1)O(1)EasyMath
11Container With Most WaterSolution ⭐O(n)O(1)MediumArray, Two Pointers
12Integer to RomanSolution ⭐O(1)O(1)MediumMath, String
13Roman to IntegerSolution ⭐O(n)O(1)MediumMath, String
14Longest Common PrefixSolutionO(n^2)O(1)EasyString
19Remove Nth Node From End of ListSolutionO(n)O(1)MediumLinked List, Two Pointers
20Valid ParenthesesSolutionO(n)O(n)EasyString, Stack
21Merge Two Sorted ListsSolutionO(n)O(n)EasyLinked List
24Swap Nodes in PairsSolutionO(n)O(1)MediumLinked List
25Reverse Nodes in k-GroupSolutionO(n)O(1)HardLinked List
26Remove Duplicates from Sorted ArraySolutionO(n)O(1)EasyArray, Two Pointers
27Remove ElementSolutionO(n)O(1)EasyArray, Two Pointers
35Search Insert PositionSolutionO(n)O(1)EasyArray, Binary Search
43Multiply StringsSolutionO(1)O(1)MediumMath, String
50Pow(x,n)SolutionO(logn)O(1)MediumMath, Binary Search
53Maximum SubarraySolutionO(n)O(1)EasyArray, Divide and Conquer, Dynamic Programming
61Plus OneSolutionO(n)O(1)EasyArray, Math
65Valid NumberSolutionO(1)O(1)HardMath, String
73Set Matrix ZeroesSolutionO(n^2)O(1)MediumArray
78SubsetsSolutionO(n^2)O(n^2)MediumArray, Backtracking, Bit Manipulation
83Remove Duplicates from Sorted ListSolutionO(n)O(1)EasyLinked List
89Gray CodeSolutionO(n^2)O(n)MediumBacktracking
118Pascal's TriangleSolutionO(n^2)O(1)EasyArray
119Pascal's Triangle IISolutionO(n^2)O(k)EasyArray
121Best Time to Buy and Sell StockSolutionO(n)O(1)EasyArray, Dynamic Programming
125Valid PalindromeSolutionO(1)O(1)EasyTwo Pointers, String
136Single NumberSolutionO(n)O(1)EasyHash Table, Bit Manipulation
141Linked List CycleSolutionO(n)O(1)EasyLinked List, Two Pointers
142Linked List Cycle IISolutionO(n)O(n)MediumLinked List, Two Pointers
160Intersection of Two Linked ListsSolutionO(n)O(n)EasyLinked List
167Two Sum II - Input array is sortedSolutionO(n)O(1)EasyArray, Two Pointers, Binary Search
169Majority ElementSolutionO(n)O(1)EasyArray, Divide and Conquer, Bit Manipulation
172Factorial Trailing ZeroesSolutionO(n)O(1)EasyMath
189Rotate ArraySolutionO(1)O(1)EasyArray
203Remove Linked List ElementsSolutionO(n)O(1)EasyLinked List
204Count PrimesSolutionO(n)O(n)EasyHash Table, Math
206Reverse Linked ListSolutionO(n)O(n)EasyLinked List
217Contains DuplicateSolutionO(n)O(n)EasyArray, Hash Table
219Contains Duplicate IISolutionO(n)O(n)EasyArray, Hash Table
231Power of TwoSolutionO(1)O(1)EasyMath, Bit Manipulation
234Palindrome Linked ListSolutionO(n)O(n)EasyLinked List, Two Pointers
237Delete Node in a Linked ListSolutionO(1)O(1)EasyLinked List
242Valid AnagramSolutionO(n)O(n)EasyHash Table, Sort
268Missing NumberSolutionO(n)O(1)EasyArray, Math, Bit Manipulation
283Move ZeroesSolutionO(n)O(1)EasyArray, Two Pointers
287Find the Duplicate NumberSolutionO(nlogn)O(1)EasyArray, Two Pointers, Binary Search
326Power of ThreeSolutionO(logn)O(1)EasyMath
328Odd Even Linked ListSolutionO(n)O(1)MediumLinked List
344Reverse StringSolutionO(1)O(1)EasyString, Two Pointer
345Reverse Vowels of a StringSolutionO(n)O(1)EasyTwo Pointers, String
349Intersection of Two ArraysSolutionO(1)O(1)EasyHash Table, Two Pointers, Binary Search, Sort
350 Intersection of Two Arrays IISolutionO(nlogn)O(n)EasyHash Table, Two Pointers, Binary Search, Sort
367Valid Perfect SquareSolutionO(n)O(1)EasyMath, Binary Search
383Ransom NoteSolutionO(n)O(n)EasyString
389Find the DifferenceSolutionO(n)O(1)EasyHash Table, Bit Manipulation
392Is SubsequenceSolutionO(n^2)O(1)EasyBinary Search, Dynamic Programming, Greedy
412Fizz BuzzSolutionO(n)O(n)EasyArray
413Arithmetic SlicesSolutionO(n)O(n)MediumMath, Dynamic Programming
415Add StringsSolutionO(n)O(n)EasyString
441Arranging CoinsSolutionO(1)O(1)EasyMath, Binary Search
443String CompressionSolutionO(n^2)O(1)EasyString
445Add Two Numbers IISolutionO(n)O(n)MediumLinked List
448Find All Numbers Disappeared in an ArraySolutionO(n)O(n)EasyArray
461Hamming DistanceSolutionO(n)O(1)EasyBit Manipulation
476Number ComplementSolutionO(n)O(n)EasyBit Manipulation
485Max Consecutive OnesSolutionO(n)O(1)EasyArray
500Keyboard RowSolutionO(n)O(n)EasyHash Table
504Base 7SolutionO(n)O(n)EasyMath
507Perfect NumberSolutionO(logn)O(1)EasyMath
509Fibonacci NumberSolutionO(n)O(1)EasyArray
535Encode and Decode TinyURLSolutionO(1)O(1)MediumString, Math
537Complex Number MultiplicationSolutionO(1)O(1)MediumHash Table, Math
557Reverse Words in a StringSolutionO(n)O(1)EasyString
561Array Partition ISolutionO(n)O(1)EasyArray
566Reshape the MatrixSolutionO(n)O(n^2)EasyArray
581Shortest Unsorted Continuous SubarraySolutionO(n)O(1)EasyArray
599Minimum Index Sum of Two ListsSolutionO(n)O(n)EasyHash Table
628Maximum Product of Three NumbersSolutionO(nlogn)O(1)EasyArray, Math
633Sum of Square NumbersSolutionO(logn)O(1)EasyMath
645Set MismatchSolutionO(1)O(n)EasyHash Table, Math
693Binary Number with Alternating BitsSolutionO(n)O(1)EasyBit Manipulation
697Degree of an ArraySolutionO(n)O(n)EasyArray
804Unique Morse Code WordsSolutionO(n^2)O(n)EasyString
832Flipping an ImageSolutionO(n^2)O(1)EasyArray
852Peak Index in a Mountain ArraySolutionO(n)O(1)EasyBinary Search
856Score of ParenthesesSolutionO(n)O(n)MediumString, Stack
860Lemonade ChangeSolutionO(n)O(1)EasyGreedy
867Transpose MatrixSolutionO(n^2)O(n^2)EasyArray
868Binary GapSolutionO(n)O(1)EasyMath
876Middle of the Linked ListSolutionO(n)O(1)EasyLinked List
884Uncommon Words from Two SentencesSolutionO(n)O(n)EasyHash Table
888Fair Candy SwapSolutionO(n)O(n)EasyArray
890Find and Replace PatternSolutionO(n^2)O(n)MediumString
896Monotonic ArraySolutionO(n)O(1)EasyArray
905Sort Array By ParitySolutionO(n)O(n)EasyArray
914X of a Kind in a Deck of CardsSolutionO(n^2)O(n)EasyString, Math
917Reverse Only LettersSolutionO(n)O(n)EasyString
921Minimum Add to Make Parentheses ValidSolutionO(n)O(n)MediumStack, Greedy
922Sort Array By Parity IISolutionO(n)O(n)EasyArray, Sort
929Unique Email AddressesSolutionO(n)O(n)EasyString
941Valid Mountain ArraySolutionO(n)O(1)EasyArray
944Delete Columns to Make SortedSolutionO(n)O(1)EasyGreedy
950Reveal Cards In Increasing OrderSolutionO(n)O(n)MediumArray
961N-Repeated Element in Size 2N ArraySolutionO(n)O(n)EasyHash Table

DATABASE

S.No.TitleSolutionsDifficulty
595Big CountriesSolutionEasy

About

Solution to LeetCode Problems in Python and Golang 🎯

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp