Skip to content
Navigation Menu
Toggle navigation
Sign in
Appearance settings
Platform
AI CODE CREATION
GitHub Copilot
Write better code with AI
GitHub Spark
Build and deploy intelligent apps
GitHub Models
Manage and compare prompts
MCP Registry
New
Integrate external tools
DEVELOPER WORKFLOWS
Actions
Automate any workflow
Codespaces
Instant dev environments
Issues
Plan and track work
Code Review
Manage code changes
APPLICATION SECURITY
GitHub Advanced Security
Find and fix vulnerabilities
Code security
Secure your code as you build
Secret protection
Stop leaks before they start
EXPLORE
Why GitHub
Documentation
Blog
Changelog
Marketplace
View all features
Solutions
BY COMPANY SIZE
Enterprises
Small and medium teams
Startups
Nonprofits
BY USE CASE
App Modernization
DevSecOps
DevOps
CI/CD
View all use cases
BY INDUSTRY
Healthcare
Financial services
Manufacturing
Government
View all industries
View all solutions
Resources
EXPLORE BY TOPIC
AI
Software Development
DevOps
Security
View all topics
EXPLORE BY TYPE
Customer stories
Events & webinars
Ebooks & reports
Business insights
GitHub Skills
SUPPORT & SERVICES
Documentation
Customer support
Community forum
Trust center
Partners
View all resources
Open Source
COMMUNITY
GitHub Sponsors
Fund open source developers
PROGRAMS
Security Lab
Maintainer Community
Accelerator
GitHub Stars
Archive Program
REPOSITORIES
Topics
Trending
Collections
Enterprise
ENTERPRISE SOLUTIONS
Enterprise platform
AI-powered developer platform
AVAILABLE ADD-ONS
GitHub Advanced Security
Enterprise-grade security features
Copilot for Business
Enterprise-grade AI features
Premium Support
Enterprise-grade 24/7 support
Pricing
Search or jump to...
Search code, repositories, users, issues, pull requests...
Search syntax tips
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Sign in
Sign up
Appearance settings
Resetting focus
You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
Dismiss alert
{{ message }}
alxn
/
leetcode
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
2
Code
Issues
0
Pull requests
0
Actions
Projects
Security
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security
Insights
alxn/leetcode
master
Branches
Tags
Go to file
Code
Open more actions menu
Folders and files
Name
Name
Last commit message
Last commit date
Latest commit
History
1 Commit
1 Commit
1-two-sum
1-two-sum
101-symmetric-tree
101-symmetric-tree
1036-rotting-oranges
1036-rotting-oranges
104-maximum-depth-of-binary-tree
104-maximum-depth-of-binary-tree
1046-max-consecutive-ones-iii
1046-max-consecutive-ones-iii
11-container-with-most-water
11-container-with-most-water
1116-maximum-level-sum-of-a-binary-tree
1116-maximum-level-sum-of-a-binary-tree
1146-greatest-common-divisor-of-strings
1146-greatest-common-divisor-of-strings
1236-n-th-tribonacci-number
1236-n-th-tribonacci-number
1250-longest-common-subsequence
1250-longest-common-subsequence
128-longest-consecutive-sequence
128-longest-consecutive-sequence
1319-unique-number-of-occurrences
1319-unique-number-of-occurrences
1335-maximum-candies-allocated-to-k-children
1335-maximum-candies-allocated-to-k-children
136-single-number
136-single-number
1392-find-the-difference-of-two-arrays
1392-find-the-difference-of-two-arrays
141-linked-list-cycle
141-linked-list-cycle
142-linked-list-cycle-ii
142-linked-list-cycle-ii
1441-minimum-flips-to-make-a-or-b-equal-to-c
1441-minimum-flips-to-make-a-or-b-equal-to-c
1474-longest-zigzag-path-in-a-binary-tree
1474-longest-zigzag-path-in-a-binary-tree
1487-cinema-seat-allocation
1487-cinema-seat-allocation
151-reverse-words-in-a-string
151-reverse-words-in-a-string
1528-kids-with-the-greatest-number-of-candies
1528-kids-with-the-greatest-number-of-candies
1544-count-good-nodes-in-binary-tree
1544-count-good-nodes-in-binary-tree
1567-maximum-number-of-vowels-in-a-substring-of-given-length
1567-maximum-number-of-vowels-in-a-substring-of-given-length
1576-reorder-routes-to-make-all-paths-lead-to-the-city-zero
1576-reorder-routes-to-make-all-paths-lead-to-the-city-zero
1586-longest-subarray-of-1s-after-deleting-one-element
1586-longest-subarray-of-1s-after-deleting-one-element
162-find-peak-element
162-find-peak-element
167-two-sum-ii-input-array-is-sorted
167-two-sum-ii-input-array-is-sorted
17-letter-combinations-of-a-phone-number
17-letter-combinations-of-a-phone-number
1777-determine-if-two-strings-are-close
1777-determine-if-two-strings-are-close
1798-max-number-of-k-sum-pairs
1798-max-number-of-k-sum-pairs
1833-find-the-highest-altitude
1833-find-the-highest-altitude
1894-merge-strings-alternately
1894-merge-strings-alternately
198-house-robber
198-house-robber
199-binary-tree-right-side-view
199-binary-tree-right-side-view
2-add-two-numbers
2-add-two-numbers
20-valid-parentheses
20-valid-parentheses
200-number-of-islands
200-number-of-islands
2038-nearest-exit-from-entrance-in-maze
2038-nearest-exit-from-entrance-in-maze
206-reverse-linked-list
206-reverse-linked-list
208-implement-trie-prefix-tree
208-implement-trie-prefix-tree
2121-find-if-path-exists-in-graph
2121-find-if-path-exists-in-graph
215-kth-largest-element-in-an-array
215-kth-largest-element-in-an-array
216-combination-sum-iii
216-combination-sum-iii
221-maximal-square
221-maximal-square
2216-delete-the-middle-node-of-a-linked-list
2216-delete-the-middle-node-of-a-linked-list
2236-maximum-twin-sum-of-a-linked-list
2236-maximum-twin-sum-of-a-linked-list
23-merge-k-sorted-lists
23-merge-k-sorted-lists
236-lowest-common-ancestor-of-a-binary-tree
236-lowest-common-ancestor-of-a-binary-tree
238-product-of-array-except-self
238-product-of-array-except-self
2413-smallest-number-in-infinite-set
2413-smallest-number-in-infinite-set
2428-equal-row-and-column-pairs
2428-equal-row-and-column-pairs
2470-removing-stars-from-a-string
2470-removing-stars-from-a-string
2553-total-cost-to-hire-k-workers
2553-total-cost-to-hire-k-workers
2665-minimum-time-to-repair-cars
2665-minimum-time-to-repair-cars
277-find-the-celebrity
277-find-the-celebrity
283-move-zeroes
283-move-zeroes
3-longest-substring-without-repeating-characters
3-longest-substring-without-repeating-characters
300-longest-increasing-subsequence
300-longest-increasing-subsequence
326-power-of-three
326-power-of-three
328-odd-even-linked-list
328-odd-even-linked-list
334-increasing-triplet-subsequence
334-increasing-triplet-subsequence
338-counting-bits
338-counting-bits
339-nested-list-weight-sum
339-nested-list-weight-sum
34-find-first-and-last-position-of-element-in-sorted-array
34-find-first-and-last-position-of-element-in-sorted-array
345-reverse-vowels-of-a-string
345-reverse-vowels-of-a-string
350-intersection-of-two-arrays-ii
350-intersection-of-two-arrays-ii
364-nested-list-weight-sum-ii
364-nested-list-weight-sum-ii
366-find-leaves-of-binary-tree
366-find-leaves-of-binary-tree
374-guess-number-higher-or-lower
374-guess-number-higher-or-lower
380-insert-delete-getrandom-o1
380-insert-delete-getrandom-o1
392-is-subsequence
392-is-subsequence
394-decode-string
394-decode-string
42-trapping-rain-water
42-trapping-rain-water
435-non-overlapping-intervals
435-non-overlapping-intervals
437-path-sum-iii
437-path-sum-iii
443-string-compression
443-string-compression
450-delete-node-in-a-bst
450-delete-node-in-a-bst
452-minimum-number-of-arrows-to-burst-balloons
452-minimum-number-of-arrows-to-burst-balloons
50-powx-n
50-powx-n
547-number-of-provinces
547-number-of-provinces
56-merge-intervals
56-merge-intervals
560-subarray-sum-equals-k
560-subarray-sum-equals-k
605-can-place-flowers
605-can-place-flowers
62-unique-paths
62-unique-paths
643-maximum-average-subarray-i
643-maximum-average-subarray-i
658-find-k-closest-elements
658-find-k-closest-elements
670-maximum-swap
670-maximum-swap
695-max-area-of-island
695-max-area-of-island
714-best-time-to-buy-and-sell-stock-with-transaction-fee
714-best-time-to-buy-and-sell-stock-with-transaction-fee
72-edit-distance
72-edit-distance
724-find-pivot-index
724-find-pivot-index
735-asteroid-collision
735-asteroid-collision
739-daily-temperatures
739-daily-temperatures
747-min-cost-climbing-stairs
747-min-cost-climbing-stairs
783-search-in-a-binary-search-tree
783-search-in-a-binary-search-tree
850-insert-into-a-sorted-circular-linked-list
850-insert-into-a-sorted-circular-linked-list
871-keys-and-rooms
871-keys-and-rooms
88-merge-sorted-array
88-merge-sorted-array
903-implement-rand10-using-rand7
903-implement-rand10-using-rand7
View all files
About
Leetcode
Uh oh!
There was an error while loading.
Please reload this page
.
Activity
Stars
2
stars
Watchers
0
watching
Forks
0
forks
Report repository
Releases
No releases published
Packages
0
Uh oh!
There was an error while loading.
Please reload this page
.
Contributors
Uh oh!
There was an error while loading.
Please reload this page
.
Languages
Go
100.0%
You can’t perform that action at this time.