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
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 }}
dc-tw
/
leetcode
Public
Notifications
You must be signed in to change notification settings
Fork
0
Star
1
Code
Issues
0
Pull requests
0
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
master
Branches
Tags
Go to file
Code
Open more actions menu
Latest commit
History
155 Commits
155 Commits
Folders and files
Name
Name
Last commit message
Last commit date
.vs
.vs
.gitignore
.gitignore
1-Two Sum.cpp
1-Two Sum.cpp
10-Regular Expression Matching.cpp
10-Regular Expression Matching.cpp
100-Same Tree.cpp
100-Same Tree.cpp
101-Symmetric Tree.cpp
101-Symmetric Tree.cpp
1015-Smallest Integer Divisible by K.cpp
1015-Smallest Integer Divisible by K.cpp
102-Binary Tree Level Order Traversal.cpp
102-Binary Tree Level Order Traversal.cpp
1020-Number of Enclaves.cpp
1020-Number of Enclaves.cpp
1026-Maximum Difference Between Node and Ancestor.cpp
1026-Maximum Difference Between Node and Ancestor.cpp
103-Binary Tree Zigzag Level Order Traversal.cpp
103-Binary Tree Zigzag Level Order Traversal.cpp
1034-Coloring A Border.cpp
1034-Coloring A Border.cpp
1038-Binary Search Tree to Greater Sum Tree.cpp
1038-Binary Search Tree to Greater Sum Tree.cpp
104-Maximum Depth of Binary Tree.cpp
104-Maximum Depth of Binary Tree.cpp
105-Construct Binary Tree from Preorder and Inorder Traversal.cpp
105-Construct Binary Tree from Preorder and Inorder Traversal.cpp
107-Binary Tree Level Order Traversal II.cpp
107-Binary Tree Level Order Traversal II.cpp
108-Convert Sorted Array to Binary Search Tree.cpp
108-Convert Sorted Array to Binary Search Tree.cpp
1080-Insufficient Nodes in Root to Leaf Paths.cpp
1080-Insufficient Nodes in Root to Leaf Paths.cpp
109-Convert Sorted List to Binary Search Tree.cpp
109-Convert Sorted List to Binary Search Tree.cpp
1091-Shortest Path in Binary Matrix.cpp
1091-Shortest Path in Binary Matrix.cpp
11-Container With Most Water.cpp
11-Container With Most Water.cpp
110-Balanced Binary Tree.cpp
110-Balanced Binary Tree.cpp
111-Minimum Depth of Binary Tree.cpp
111-Minimum Depth of Binary Tree.cpp
1110-Delete Nodes And Return Forest.cpp
1110-Delete Nodes And Return Forest.cpp
1111-Maximum Nesting Depth of Two Valid Parentheses Strings.cpp
1111-Maximum Nesting Depth of Two Valid Parentheses Strings.cpp
1114-Print in Order.cpp
1114-Print in Order.cpp
112-Path Sum.cpp
112-Path Sum.cpp
1123-Lowest Common Ancestor of Deepest Leaves.cpp
1123-Lowest Common Ancestor of Deepest Leaves.cpp
1129-Shortest Path with Alternating Colors.cpp
1129-Shortest Path with Alternating Colors.cpp
113-Path Sum II.cpp
113-Path Sum II.cpp
1138-Alphabet Board Path.cpp
1138-Alphabet Board Path.cpp
1144-Decrease Elements To Make Array Zigzag.cpp
1144-Decrease Elements To Make Array Zigzag.cpp
1145-Binary Tree Coloring Game.cpp
1145-Binary Tree Coloring Game.cpp
115-Distinct Subsequences.cpp
115-Distinct Subsequences.cpp
1154-Day of the Year.cpp
1154-Day of the Year.cpp
116-Populating Next Right Pointers in Each Node.cpp
116-Populating Next Right Pointers in Each Node.cpp
1162-As Far from Land as Possible.cpp
1162-As Far from Land as Possible.cpp
117-Populating Next Right Pointers in Each Node II.cpp
117-Populating Next Right Pointers in Each Node II.cpp
1175-Prime Arrangements.cpp
1175-Prime Arrangements.cpp
118-Pascal's Triangle.cpp
118-Pascal's Triangle.cpp
12-Integer to Roman.cpp
12-Integer to Roman.cpp
120-Triangle.cpp
120-Triangle.cpp
1207-Unique Number of Occurrences.cpp
1207-Unique Number of Occurrences.cpp
121-Best Time to Buy and Sell Stock.cpp
121-Best Time to Buy and Sell Stock.cpp
122-Best Time to Buy and Sell Stock II.cpp
122-Best Time to Buy and Sell Stock II.cpp
123-Best Time to Buy and Sell Stock III.cpp
123-Best Time to Buy and Sell Stock III.cpp
124-Binary Tree Maximum Path Sum.cpp
124-Binary Tree Maximum Path Sum.cpp
125- Valid Palindrome.cpp
125- Valid Palindrome.cpp
1254-Number of Closed Islands.cpp
1254-Number of Closed Islands.cpp
126-Word Ladder II.cpp
126-Word Ladder II.cpp
127-Word Ladder.cpp
127-Word Ladder.cpp
128-Longest Consecutive Sequence.cpp
128-Longest Consecutive Sequence.cpp
129-Sum Root to Leaf Numbers.cpp
129-Sum Root to Leaf Numbers.cpp
13- Roman to Integer.cpp
13- Roman to Integer.cpp
130-Surrounded Regions.cpp
130-Surrounded Regions.cpp
131-Palindrome Partitioning.cpp
131-Palindrome Partitioning.cpp
133-Clone Graph.cpp
133-Clone Graph.cpp
134-Gas Station.cpp
134-Gas Station.cpp
136-Single Number.cpp
136-Single Number.cpp
138-Copy List with Random Pointer.cpp
138-Copy List with Random Pointer.cpp
139-Word Break.cpp
139-Word Break.cpp
14-Longest Common Prefix.cpp
14-Longest Common Prefix.cpp
140-Word Break II.cpp
140-Word Break II.cpp
141-Linked List Cycle.cpp
141-Linked List Cycle.cpp
142-Linked List Cycle II.cpp
142-Linked List Cycle II.cpp
146-LRU Cache.cpp
146-LRU Cache.cpp
147-Insertion Sort List.cpp
147-Insertion Sort List.cpp
148-Sort List.cpp
148-Sort List.cpp
149-Max Points on a Line.cpp
149-Max Points on a Line.cpp
15-3Sum.cpp
15-3Sum.cpp
150-Evaluate Reverse Polish Notation.cpp
150-Evaluate Reverse Polish Notation.cpp
152-Maximum Product Subarray.cpp
152-Maximum Product Subarray.cpp
153-Find Minimum in Rotated Sorted Array.cpp
153-Find Minimum in Rotated Sorted Array.cpp
154-Find Minimum in Rotated Sorted Array II.cpp
154-Find Minimum in Rotated Sorted Array II.cpp
155-Min Stack.cpp
155-Min Stack.cpp
160-Intersection of Two Linked Lists.cpp
160-Intersection of Two Linked Lists.cpp
162-Find Peak Element.cpp
162-Find Peak Element.cpp
166-Fraction to Recurring Decimal.cpp
166-Fraction to Recurring Decimal.cpp
167-Two Sum II - Input array is sorted.cpp
167-Two Sum II - Input array is sorted.cpp
168-Excel Sheet Column Title.cpp
168-Excel Sheet Column Title.cpp
169-Majority Element.cpp
169-Majority Element.cpp
17-Letter Combinations of a Phone Number.cpp
17-Letter Combinations of a Phone Number.cpp
171-Excel Sheet Column Number.cpp
171-Excel Sheet Column Number.cpp
172-Factorial Trailing Zeroes.cpp
172-Factorial Trailing Zeroes.cpp
173-Binary Search Tree Iterator.cpp
173-Binary Search Tree Iterator.cpp
174-Dungeon Game.cpp
174-Dungeon Game.cpp
179-Largest Number.cpp
179-Largest Number.cpp
18-4Sum.cpp
18-4Sum.cpp
188-Best Time to Buy and Sell Stock IV.cpp
188-Best Time to Buy and Sell Stock IV.cpp
189-Rotate Array.cpp
189-Rotate Array.cpp
19-Remove Nth Node From End of List.cpp
19-Remove Nth Node From End of List.cpp
190-Reverse Bits.cpp
190-Reverse Bits.cpp
191-Number of 1 Bits.cpp
191-Number of 1 Bits.cpp
198-House Robber.cpp
198-House Robber.cpp
199-Binary Tree Right Side View.cpp
199-Binary Tree Right Side View.cpp
2-Add Two Numbers.cpp
2-Add Two Numbers.cpp
20-Valid Parentheses.cpp
20-Valid Parentheses.cpp
200-Number of Islands.cpp
200-Number of Islands.cpp
201-Bitwise AND of Numbers Range.cpp
201-Bitwise AND of Numbers Range.cpp
202-Happy Number.cpp
202-Happy Number.cpp
View all files
Repository files navigation
README
More
items
Leetcode
Code in python3 or C++ or C
About
No description, website, or topics provided.
Resources
Readme
Activity
Stars
1
star
Watchers
2
watching
Forks
0
forks
Report repository
Releases
Packages
Used by
Contributors
Languages
You can’t perform that action at this time.