GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - yuchia0221/Leetcode: About Leetcode Solutions in Python

BranchesTags
Open more actions menu

Latest commit

 

History

510 Commits
510 Commits

Folders and files

NameName
Last commit message
Last commit date
Array
Array
 
 
Backtracking
Backtracking
 
 
Binary Search Tree
Binary Search Tree
 
 
Binary Search
Binary Search
 
 
Binary Tree
Binary Tree
 
 
Breadth-first Search
Breadth-first Search
 
 
Depth-first Search
Depth-first Search
 
 
Design
Design
 
 
Dynamic Programming
Dynamic Programming
 
 
Hash Table
Hash Table
 
 
Heap
Heap
 
 
Linked List
Linked List
 
 
Prefix Sum
Prefix Sum
 
 
Segment Tree/307-RangeSumQuery
Segment Tree/307-RangeSumQuery
 
 
Sliding Window
Sliding Window
 
 
Stack
Stack
 
 
String
String
 
 
Trie
Trie
 
 
Two Pointers
Two Pointers
 
 
Union Find
Union Find
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 

Repository files navigation

Leetcode

This repository is a software engineer interview prepration, which provides solutions for leetcode questions in Python.

Problem Solved: 235
  • Array (26)
  • Backtracking (13)
  • Binary Serch (13)
  • Binary Search Tree (6)
  • Binary Tree (19)
  • Breadth-first Search (7)
  • Depth-first Search (16)
  • Design (4)
  • Dynamic Programming (20)
  • Hash Table (24)
  • Heap / Priority Queue (5)
  • Linked List (17)
  • Prefix Sum (9)
  • Segment Tree (1)
  • Sliding Window (7)
  • Stack (6)
  • String (14)
  • Trie (2)
  • Two Pointers (14)
  • Union Find (12)

Array

  • Encode and Decode Strings: Solution
  • Kth Largest Element in an Array: Solution
  • Interval List Intersections: Solution
  • Merge Intervals: Solution
  • Insert Interval: Solution
  • Meeting rooms: Solution
  • Meeting rooms II: Solution
  • Rotate Image: Solution
  • Set Matrix Zeroes: Solution
  • Game of Life: Solution
  • Jump Game: Solution
  • Jump Game II: Solution
  • Find Players With Zero or One Losses: Solution
  • Reorder Data in Log Files: Solution
  • Maximum Area of a Piece of Cake After Horizontal and Vertical Cuts: Solution
  • Find the Kth Largest Integer in the Array:Solution
  • Maximum Bags With Full Capacity of Rocks: Solution
  • Best Time to Buy and Sell Stock II: Solution
  • Delete Columns to Make Sorted: Solution
  • Minimum Number of Arrows to Burst Balloons: Solution
  • Maximum Ice Cream Bars: Solution
  • Maximum Sum Circular Subarray: Solution
  • Shuffle the Array: Solution
  • Wiggle Sort: Solution
  • Add to Array-Form of Integer: Solution
  • Summary Ranges: Solution

Backtracking

  • Combinations: Solution
  • Combination Sum II: Solution
  • Permutations II: Solution
  • Subsets: Solution
  • Subsets II: Solution
  • N-Queens: Solution
  • Factor Combinations: Solution
  • Remove Invalid Parentheses: Solution
  • Increasing Subsequences: Solution
  • Number of Ways of Cutting a Pizza: Solution
  • Target Sum: Solution
  • Palindrome Partitioning: Solution
  • Restore IP Addresses: Solution

Binary Search

  • Binary Search: Solution
  • Find First and Last Position of Element in Sorted Arra: Solution
  • Search in a Sorted Array of Unknown Size: Solution
  • Median of Two Sorted Arrays: Solution
  • Search a 2D Matrix: Solution
  • Find Peak Element: Solution
  • Koko Eating Bananas: Solution
  • Find the Smallest Divisor Given a Threshold: Solution
  • Find K Closest Elements: Solution
  • Search in Rotated Sorted Array II: Solution
  • Search Insert Position: Solution
  • Single Element in a Sorted Array: Solution
  • Capacity To Ship Packages Within D Days: Solution

Binary Search Tree

  • Binary Search Tree Iterator: Solution
  • Kth Smallest Element in a BST: Solution
  • Inorder Successor in BST: Solution
  • Minimum Distance Between BST Nodes: Solution
  • Minimum Absolute Difference in BST: Solution
  • Number of Ways to Reorder Array to Get Same BST: Solution

Binary Tree

  • Binary Tree Zigzag Level Order Traversal: Solution
  • Binary Tree Level Order Traversal II: Solution
  • Find Bottom Left Tree Value: Solution
  • Binary Tree Inorder Traversal: Solution
  • Binary Tree Preorder Traversal: Solution
  • Binary Tree Postorder Traversal: Solution
  • Construct Binary Tree from Inorder and Postorder Traversal: Solution
  • Construct Binary Tree from Preorder and Postorder Traversal: Solution
  • Same Tree: : Solution
  • Symmetric Tree: Solution
  • Balanced Binary Tree: Solution
  • Minimum Depth of Binary Tree: Solution
  • Path Sum: Solution
  • Path Sum II: Solution
  • Binary Tree Maximum Path Sum: Solution
  • Verify Preorder Serialization of a Binary Tree: Solution
  • Binary Tree Paths: Solution
  • Flatten Binary Tree to Linked List: Solution
  • Maximum Level Sum of a Binary Tree: Solution

Breadth-first Search

  • The Maze II: Solution
  • Possible Bipartition: Solution
  • Find the Celebrity: Solution
  • Snakes and Ladders: Solution
  • Find Closest Node to Given Two Nodes: Solution
  • As Far from Land as Possible: Solution
  • Shortest Path with Alternating Colors: Solution

Depth-first Search

  • Course Schedule II: Solution
  • Alien Dictionary: Solution
  • The Maze: Solution
  • Graph Valid Tree: Solution
  • Keys and Rooms: Solution
  • Number of Distinct Islands: Solution
  • Critical Connections in a Network: Solution
  • All Paths From Source to Target: Solution
  • Unique Paths III: Solution
  • Longest Path With Different Adjacent Characters: Solution
  • Concatenated Words: Solution
  • Max Area of Island: Solution
  • Minimum Fuel Cost to Report to the Capital: Solution
  • Construct Quad Tree: Solution
  • Clone Binary Tree With Random Pointer: Solution
  • Reorder Routes to Make All Paths Lead to the City Zero: Solution

Design

  • Data Stream as Disjoint Intervals: Solution
  • Stock Price Fluctuation: Solution
  • Design Browser History: Solution
  • Snapshot Array: Solution

Dynamic Programming

  • Integer Break: Solution
  • Integer Replacement: Solution
  • Word Break II: Solution
  • Regular Expression Matching: Solution
  • Burst Balloons: Solution
  • Longest Palindromic Subsequence: Solution
  • Unique Path II: Solution
  • Minimum Path Sum: Solution
  • Maximal Square: Solution
  • Decode Ways: Solution
  • Binary Trees With Factors: Solution
  • Sum of Subarray Minimums: Solution
  • Number of Dice Rolls With Target Sum: Solution
  • Best Time to Buy and Sell Stock with Cooldown: Solution
  • Maximum Profit From Trading Stocks: Solution
  • Best Time to Buy and Sell Stock III: Solution
  • Best Time to Buy and Sell Stock IV: Solution
  • N-th Tribonacci Number: Solution
  • Edit Distance: Solution
  • Make Array Strictly Increasing: Solution

Hash Table

  • Two Sum: Solution
  • Valid Sudoku: Solution
  • Group Anagrams: Solution
  • Contains Duplicate: Solution
  • Valid Anagram: Solution
  • Top K Frequent Elements: Solution
  • Longest Consecutive Sequence: Solution
  • Intersection of Two Arrays: Solution
  • Intersection of Two Arrays II: Solution
  • 4Sum: Solution
  • Find All Duplicates in an Array: Solution
  • Verifying an Alien Dictionary: Solution
  • Design HashMap: Solution
  • LFU Cache: Solution
  • Design Underground System: Solution
  • Pairs of Songs With Total Durations Divisible by 60: Solution
  • Analyze User Website Visit Pattern: Solution
  • Subdomain Visit Count: Solution
  • Split Array into Consecutive Subsequences: Solution
  • Word Subsets: Solution
  • Word Pattern: Solution
  • Minimum Rounds to Complete All Tasks: Solution
  • Sentence Similarity: Solution
  • Naming a Company: Solution
  • Equal Row and Column Pairs: Solution

Heap

  • The Skyline Problem: Solution
  • Reorganize String: Solution
  • Remove Stones to Minimize the Total: Solution
  • Single-Threaded CPU: Solution
  • IPO: Solution

Linked List

  • Multiply Strings: Solution
  • Partition List: Solution
  • Linked List Cycle: Solution
  • Intersection of Two Linked Lists: Solution
  • Palindrome Linked List: Solution
  • Odd Even Linked List: Solution
  • Remove Duplicates From an Unsorted Linked List: Solution
  • Add Two Numbers: Solution
  • Reverse Nodes in k-Group: Solution
  • Remove Duplicates from Sorted List: Solution
  • Remove Duplicates from Sorted List II: Solution
  • Reverse Linked List II: Solution
  • Copy List with Random Pointer: Solution
  • Sort List: Solution
  • Remove Linked List Elements: Solution
  • Add Two Numbers II: Solution
  • Linked List Cycle II: Solution

Prefix Sum

  • Product of Array Except Self: Solution
  • Maximum Subarray: Solution
  • Range sum query - immutable: Solution
  • Maximum Size Subarray Sum Equals k: Solution
  • Subarray Sum Equals K: Solution
  • Random Pick with Weight: Solution
  • Subarray Sums Divisible by K: Solution
  • Minimum Average Difference: Solution
  • Continuous Subarray Sum: Solution

Segment Tree

  • Range Sum Query: Solution

Sliding Window

  • Minimum Window Substring: Solution
  • Minimum Size Subarray Sum: Solution
  • Sliding Window Maximum: Solution
  • Subarray Product Less Than K: Solution
  • Fruit Into Baskets: Solution
  • Substring with Concatenation of All Words: Solution
  • K Radius Subarray Averages: Solution

Stack

  • Basic Calculator II: Solution
  • Decode String: Solution
  • Minimum Remove to Make Valid Parentheses: Solution
  • Next Greater Node In Linked List: Solution
  • Daily Temperatures: Solution
  • Asteroid Collision: Solution

String

  • Longest Palindromic Substring: Solution
  • Reverse Vowels of a String: Solution
  • Valid Palindrome II: Solution
  • Longest Substring Without Repeating Characters: Solution
  • Remove All Adjacent Duplicates in String II: Solution
  • Zigzag Conversion: Solution
  • Roman to Integer: Solution
  • Longest Common Prefix: Solution
  • Text Justification: Solution
  • String Compression: Solution
  • Partition Labels: Solution
  • Break a Palindrome: Solution
  • Search Suggestions System: Solution
  • Detect Capital: Solution

Trie

  • Design Add and Search Words Data Structure: Solution
  • Design In-Memory File System: Solution

Two Pointers

  • Valid Palindrome: Solution
  • 167-TwoSumII-InputArrayIsSorted: Solution
  • 3Sum: Solution
  • Container With Most Water: Solution
  • Trapping Rain Water: Solution
  • Sort an Array: Solution
  • Sort Colors: Solution
  • Remove Duplicates from Sorted Array: Solution
  • Remove Duplicates from Sorted Array II: Solution
  • Merge Sorted Array: Solution
  • Move Zeros: Solution
  • Longest Mountain in Array: Solution
  • Multiply Strings: Solution
  • Next Permutation: Solution

Union Find

  • Number of Islands II: Solution
  • Evaluate Division: Solution
  • Largest Component Size by Common Factor: Solution
  • Find if Path Exists in Graph: Solution
  • Number of Connected Components in an Undirected Graph: Solution
  • Regions Cut By Slashes: Solution
  • The Earliest Moment When Everyone Become Friends: Solution
  • Lexicographically Smallest Equivalent String: Solution
  • Satisfiability of Equality Equations: Solution
  • Most Stones Removed with Same Row or Column: Solution
  • Number of Operations to Make Network Connected: Solution
  • Count Unreachable Pairs of Nodes in an Undirected Graph: Solution

About

About Leetcode Solutions in Python

Topics

data-structuresleetcodeleetcode-solutionspythohn

Resources

Readme
Activity

Stars

2 stars

Watchers

1 watching

Forks

1 fork
Report repository

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.