Skip to content
Navigation Menu
Sign in
Appearance settings
Platform
AI CODE CREATION
GitHub Copilot
Write better code with AI
GitHub Copilot app
Direct agents from issue to merge
MCP Registry
Integrate external tools
DEVELOPER WORKFLOWS
Actions
Automate any workflow
Codespaces
Instant dev environments
Issues
Plan and track work
Code Review
Manage code changes
Code Quality
Enforce quality at merge
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
Type
/
to search
Sign in
Sign up
Appearance settings
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 }}
benwu25
/
LeetCode
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Issues
0
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
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
141 Commits
141 Commits
0007-reverse-integer.cpp
0007-reverse-integer.cpp
0015-3Sum.cpp
0015-3Sum.cpp
0016-3-sum-closest.cpp
0016-3-sum-closest.cpp
0018-4-sum.cpp
0018-4-sum.cpp
0056-merge-intervals.cpp
0056-merge-intervals.cpp
0074-search-a-2D-matrix.cpp
0074-search-a-2D-matrix.cpp
0086-partition-list.java
0086-partition-list.java
0102-binary-tree-level-order-traversal.cpp
0102-binary-tree-level-order-traversal.cpp
0116-populating-next-right-pointers-in-each-node.cpp
0116-populating-next-right-pointers-in-each-node.cpp
0128-longest-consecutive-sequence.cpp
0128-longest-consecutive-sequence.cpp
0133-clone-graph.cpp
0133-clone-graph.cpp
0146-lru-cache.cpp
0146-lru-cache.cpp
0162-two-sum-II-input-array-is-sorted.cpp
0162-two-sum-II-input-array-is-sorted.cpp
0208-implement-trie.cpp
0208-implement-trie.cpp
0229-majority-element-II.cpp
0229-majority-element-II.cpp
0236-lowest-common-ancestor-of-a-binary-tree.cpp
0236-lowest-common-ancestor-of-a-binary-tree.cpp
0307-range-sum-query-mutable.cpp
0307-range-sum-query-mutable.cpp
0315-count-of-smaller-numbers-after-self.cpp
0315-count-of-smaller-numbers-after-self.cpp
0327-count-of-range-sum.cpp
0327-count-of-range-sum.cpp
0352-data-stream-as-disjoint-intervals.cpp
0352-data-stream-as-disjoint-intervals.cpp
0515-find-largest-value-in-each-tree-row.cpp
0515-find-largest-value-in-each-tree-row.cpp
0662-maximum-width-of-binary-tree.cpp
0662-maximum-width-of-binary-tree.cpp
0684-redundant-connection.cpp
0684-redundant-connection.cpp
0687-longest-univalue-path.cpp
0687-longest-univalue-path.cpp
0785-is-graph-bipartite.cpp
0785-is-graph-bipartite.cpp
0865-smallest-subtree-with-all-the-deepest-nodes.cpp
0865-smallest-subtree-with-all-the-deepest-nodes.cpp
0886-possible-bipartition.cpp
0886-possible-bipartition.cpp
0904-fruit-into-baskets.cpp
0904-fruit-into-baskets.cpp
0951-flip-equivalent-binary-trees.cpp
0951-flip-equivalent-binary-trees.cpp
0988-smallest-string-starting-from-leaf.cpp
0988-smallest-string-starting-from-leaf.cpp
1004-max-consecutive-ones-III.cpp
1004-max-consecutive-ones-III.cpp
1046-last-stone-weight.cpp
1046-last-stone-weight.cpp
1048-longest-string-chain.cpp
1048-longest-string-chain.cpp
1061-lexicographically-smallest-equivalent-string.cpp
1061-lexicographically-smallest-equivalent-string.cpp
1081-smallest-subsequence-of-distinct-characters.cpp
1081-smallest-subsequence-of-distinct-characters.cpp
11-container-with-most-water.cpp
11-container-with-most-water.cpp
1123-lowest-common-ancestor-of-deepest-leaves.cpp
1123-lowest-common-ancestor-of-deepest-leaves.cpp
113-path-sum-II.cpp
113-path-sum-II.cpp
1161-maximum-level-sum-of-a-binary-tree.cpp
1161-maximum-level-sum-of-a-binary-tree.cpp
120-triangle.cpp
120-triangle.cpp
1202-smallest-string-with-swaps.cpp
1202-smallest-string-with-swaps.cpp
121-best-time-to-buy-and-sell-stock.cpp
121-best-time-to-buy-and-sell-stock.cpp
125-valid-palindrome.cpp
125-valid-palindrome.cpp
1298-maximum-candies-you-can-get-from-boxes.cpp
1298-maximum-candies-you-can-get-from-boxes.cpp
130-surrounded-regions.cpp
130-surrounded-regions.cpp
136-single-number.cpp
136-single-number.cpp
14-longest-common-prefix.cpp
14-longest-common-prefix.cpp
153-find-minimum-in-rotated-sorted-array.cpp
153-find-minimum-in-rotated-sorted-array.cpp
1673-find-the-most-competitive-subsequence.cpp
1673-find-the-most-competitive-subsequence.cpp
1717-maximum-score-from-removing-substrings.cpp
1717-maximum-score-from-removing-substrings.cpp
1962-remove-stones-to-minimize-the-total.cpp
1962-remove-stones-to-minimize-the-total.cpp
198-house-robber.cpp
198-house-robber.cpp
1980-find-unique-binary-string.cpp
1980-find-unique-binary-string.cpp
20-valid-parenthesis.cpp
20-valid-parenthesis.cpp
200-number-of-islands.cpp
200-number-of-islands.cpp
207-course-schedule.cpp
207-course-schedule.cpp
21-merge-two-sorted-lists.cpp
21-merge-two-sorted-lists.cpp
2125-number-of-laser-beams-in-a-bank.cpp
2125-number-of-laser-beams-in-a-bank.cpp
213-house-robber-II.cpp
213-house-robber-II.cpp
221-maximal-square.cpp
221-maximal-square.cpp
2257-count-unguarded-cells-in-the-grid.cpp
2257-count-unguarded-cells-in-the-grid.cpp
228-summary-ranges.cpp
228-summary-ranges.cpp
2319-check-if-matrix-is-x-matrix.cpp
2319-check-if-matrix-is-x-matrix.cpp
2358-maximum-number-of-groups-entering-a-competition.cpp
2358-maximum-number-of-groups-entering-a-competition.cpp
2369-check-if-there-is-a-valid-partition-for-the-array.cpp
2369-check-if-there-is-a-valid-partition-for-the-array.cpp
242-valid-anagram.cpp
242-valid-anagram.cpp
2439-minimize-maximum-of-array.cpp
2439-minimize-maximum-of-array.cpp
2679-sum-in-a-matrix.cpp
2679-sum-in-a-matrix.cpp
2711-difference-of-number-of-distinct-values-on-diagonals.cpp
2711-difference-of-number-of-distinct-values-on-diagonals.cpp
279-perfect-squares.cpp
279-perfect-squares.cpp
2908-minimum-sum-of-mountain-triplets-I.cpp
2908-minimum-sum-of-mountain-triplets-I.cpp
2928-distribute-candies-among-children-I.cpp
2928-distribute-candies-among-children-I.cpp
2929-distribute-candies-among-children-II.cpp
2929-distribute-candies-among-children-II.cpp
300-longest-increasing-subsequence.cpp
300-longest-increasing-subsequence.cpp
3026-maximum-good-subarray-sum.cpp
3026-maximum-good-subarray-sum.cpp
3075-maximize-happiness-of-selected-children.cpp
3075-maximize-happiness-of-selected-children.cpp
3091-apply-operations-to-make-sum-of-array-greater-than-or-equal-to-k.cpp
3091-apply-operations-to-make-sum-of-array-greater-than-or-equal-to-k.cpp
316-remove-duplicate-letters.cpp
316-remove-duplicate-letters.cpp
3160-find-the-number-of-distinct-colors-among-the-balls.cpp
3160-find-the-number-of-distinct-colors-among-the-balls.cpp
3162-find-the-number-of-good-pairs.cpp
3162-find-the-number-of-good-pairs.cpp
319-bulb-switcher.cpp
319-bulb-switcher.cpp
322-coin-change.cpp
322-coin-change.cpp
3318-find-x-sum-of-all-k-long-subarrays.cpp
3318-find-x-sum-of-all-k-long-subarrays.cpp
3330-find-the-original-typed-string-I.cpp
3330-find-the-original-typed-string-I.cpp
3349-adjacent-increasing-subarrays-detection-I.cpp
3349-adjacent-increasing-subarrays-detection-I.cpp
3354-make-array-elements-equal-to-zero.cpp
3354-make-array-elements-equal-to-zero.cpp
3370-smallest-number-with-all-set-bits.cpp
3370-smallest-number-with-all-set-bits.cpp
344-reverse-string.cpp
344-reverse-string.cpp
3442-maximum-difference-between-even-and-odd-frequency-I.cpp
3442-maximum-difference-between-even-and-odd-frequency-I.cpp
347-top-k-frequent-elements.cpp
347-top-k-frequent-elements.cpp
3545-minimum-deletions-for-at-most-k-distinct-characters.cpp
3545-minimum-deletions-for-at-most-k-distinct-characters.cpp
3546-equal-sum-grid-partition.cpp
3546-equal-sum-grid-partition.cpp
3550-smallest-index-with-digit-sum-equal-to-index.cpp
3550-smallest-index-with-digit-sum-equal-to-index.cpp
3560-find-minimum-log-transportation-cost.cpp
3560-find-minimum-log-transportation-cost.cpp
3576-transform-array-to-all-equal-elements.cpp
3576-transform-array-to-all-equal-elements.cpp
3607-power-grid-maintenance.cpp
3607-power-grid-maintenance.cpp
3663-find-the-least-frequent-digit.cpp
3663-find-the-least-frequent-digit.cpp
3720-lexicographically-smallest-permutation-greater-than-target.cpp
3720-lexicographically-smallest-permutation-greater-than-target.cpp
3728-stable-subarrays-with-equal-boundary-and-interior-sum.cpp
3728-stable-subarrays-with-equal-boundary-and-interior-sum.cpp
424-longest-repeating-character-replacement.cpp
424-longest-repeating-character-replacement.cpp
View all files
About
leetcode.com/u/bwu25/
Activity
Stars
0
stars
Watchers
0
watching
Forks
0
forks
Report repository
Releases
Packages
Contributors
Languages
You can’t perform that action at this time.