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
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 }}
Kanchan-Bartwal
/
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 and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
main
Branches
Tags
Go to file
Code
Open more actions menu
Latest commit
History
194 Commits
194 Commits
Folders and files
Name
Name
Last commit message
Last commit date
1. Two Sum.cpp
1. Two Sum.cpp
100. Same Tree.cpp
100. Same Tree.cpp
101. Symmetric Tree.cpp
101. Symmetric Tree.cpp
1013. Partition Array Into Three Parts With Equal Sum.cpp
1013. Partition Array Into Three Parts With Equal Sum.cpp
102. Binary Tree Level Order Traversal.cpp
102. Binary Tree Level Order Traversal.cpp
1022. Sum of Root To Leaf Binary Numbers.cpp
1022. Sum of Root To Leaf Binary Numbers.cpp
104. Maximum Depth of Binary Tree.cpp
104. Maximum Depth of Binary Tree.cpp
111. Minimum Depth of Binary Tree.cpp
111. Minimum Depth of Binary Tree.cpp
112. Path Sum.cpp
112. Path Sum.cpp
1137. N-th Tribonacci Number.cpp
1137. N-th Tribonacci Number.cpp
118. Pascal's Triangle.cpp
118. Pascal's Triangle.cpp
121. Best Time to Buy and Sell Stock.cpp
121. Best Time to Buy and Sell Stock.cpp
127. Word Ladder.cpp
127. Word Ladder.cpp
1288. Remove Covered Intervals.cpp
1288. Remove Covered Intervals.cpp
1290. Convert Binary Number in a Linked List to Integer.cpp
1290. Convert Binary Number in a Linked List to Integer.cpp
1302. Deepest Leaves Sum.cpp
1302. Deepest Leaves Sum.cpp
1305. All Elements in Two Binary Search Trees.cpp
1305. All Elements in Two Binary Search Trees.cpp
133. Clone Graph.cpp
133. Clone Graph.cpp
1332. Remove Palindromic Subsequences.cpp
1332. Remove Palindromic Subsequences.cpp
136. Single Number.cpp
136. Single Number.cpp
137. Single Number II.cpp
137. Single Number II.cpp
1394. Find Lucky Integer in an Array.cpp
1394. Find Lucky Integer in an Array.cpp
141. Linked List Cycle.cpp
141. Linked List Cycle.cpp
1431. Kids With the Greatest Number of Candies.cpp
1431. Kids With the Greatest Number of Candies.cpp
1436. Destination City.cpp
1436. Destination City.cpp
144. Binary Tree Preorder Traversal.cpp
144. Binary Tree Preorder Traversal.cpp
145. Binary Tree Postorder Traversal.cpp
145. Binary Tree Postorder Traversal.cpp
1450. Number of Students Doing Homework at a Given Time.cpp
1450. Number of Students Doing Homework at a Given Time.cpp
148. Sort List.cpp
148. Sort List.cpp
1480. Running Sum of 1d Array.cpp
1480. Running Sum of 1d Array.cpp
1512. Number of Good Pairs.cpp
1512. Number of Good Pairs.cpp
1528. Shuffle String.cpp
1528. Shuffle String.cpp
1550. Three Consecutive Odds.cpp
1550. Three Consecutive Odds.cpp
1572. Matrix Diagonal Sum.cpp
1572. Matrix Diagonal Sum.cpp
160. Intersection of Two Linked Lists.cpp
160. Intersection of Two Linked Lists.cpp
1603. Design Parking System.cpp
1603. Design Parking System.cpp
165. Compare Version Numbers.cpp
165. Compare Version Numbers.cpp
1662. Check If Two String Arrays are Equivalent.cpp
1662. Check If Two String Arrays are Equivalent.cpp
167. Two Sum II - Input Array Is Sorted.cpp
167. Two Sum II - Input Array Is Sorted.cpp
1672. Richest Customer Wealth.cpp
1672. Richest Customer Wealth.cpp
1675. Minimize Deviation in Array.cpp
1675. Minimize Deviation in Array.cpp
1688. Count of Matches in Tournament.cpp
1688. Count of Matches in Tournament.cpp
169. Majority Element.cpp
169. Majority Element.cpp
1704. Determine if String Halves Are Alike.cpp
1704. Determine if String Halves Are Alike.cpp
171. Excel Sheet Column Number.cpp
171. Excel Sheet Column Number.cpp
1720. Decode XORed Array.cpp
1720. Decode XORed Array.cpp
1721. Swapping Nodes in a Linked List.cpp
1721. Swapping Nodes in a Linked List.cpp
1748. Sum of Unique Elements.cpp
1748. Sum of Unique Elements.cpp
1758. Minimum Changes To Make Alternating Binary String.cpp
1758. Minimum Changes To Make Alternating Binary String.cpp
1768. Merge Strings Alternately.cpp
1768. Merge Strings Alternately.cpp
1773. Count Items Matching a Rule.cpp
1773. Count Items Matching a Rule.cpp
1779. Find Nearest Point That Has the Same X or Y Coordinate.cpp
1779. Find Nearest Point That Has the Same X or Y Coordinate.cpp
1784. Check if Binary String Has at Most One Segment of Ones.cpp
1784. Check if Binary String Has at Most One Segment of Ones.cpp
1791. Find Center of Star Graph.cpp
1791. Find Center of Star Graph.cpp
1796. Second Largest Digit in a String.cpp
1796. Second Largest Digit in a String.cpp
1800. Maximum Ascending Subarray Sum.cpp
1800. Maximum Ascending Subarray Sum.cpp
1812. Determine Color of a Chessboard Square.cpp
1812. Determine Color of a Chessboard Square.cpp
1816. Truncate Sentence.cpp
1816. Truncate Sentence.cpp
1822. Sign of the Product of an Array.cpp
1822. Sign of the Product of an Array.cpp
1832. Check if the Sentence Is Pangram.cpp
1832. Check if the Sentence Is Pangram.cpp
1876. Substrings of Size Three with Distinct Characters.cpp
1876. Substrings of Size Three with Distinct Characters.cpp
1880. Check if Word Equals Summation of Two Words.cpp
1880. Check if Word Equals Summation of Two Words.cpp
1886. Determine Whether Matrix Can Be Obtained By Rotation.cpp
1886. Determine Whether Matrix Can Be Obtained By Rotation.cpp
1897. Redistribute Characters to Make All Strings Equal.cpp
1897. Redistribute Characters to Make All Strings Equal.cpp
1903. Largest Odd Number in String.cpp
1903. Largest Odd Number in String.cpp
191. Number of 1 Bits.cpp
191. Number of 1 Bits.cpp
1929. Concatenation of Array.cpp
1929. Concatenation of Array.cpp
1935. Maximum Number of Words You Can Type.cpp
1935. Maximum Number of Words You Can Type.cpp
1941. Check if All Characters Have Equal Number of Occurrences.cpp
1941. Check if All Characters Have Equal Number of Occurrences.cpp
1952. Three Divisors.cpp
1952. Three Divisors.cpp
1961. Check If String Is a Prefix of Array.cpp
1961. Check If String Is a Prefix of Array.cpp
1979. Find Greatest Common Divisor of Array.cpp
1979. Find Greatest Common Divisor of Array.cpp
1991. Find the Middle Index in Array.cpp
1991. Find the Middle Index in Array.cpp
1995. Count Special Quadruplets.cpp
1995. Count Special Quadruplets.cpp
20. Valid Parentheses.cpp
20. Valid Parentheses.cpp
2000. Reverse Prefix of Word.cpp
2000. Reverse Prefix of Word.cpp
2006. Count Number of Pairs With Absolute Difference K.cpp
2006. Count Number of Pairs With Absolute Difference K.cpp
2011. Final Value of Variable After Performing Operations.cpp
2011. Final Value of Variable After Performing Operations.cpp
2016. Maximum Difference Between Increasing Elements.cpp
2016. Maximum Difference Between Increasing Elements.cpp
202. Happy Number.cpp
202. Happy Number.cpp
2022. Convert 1D Array Into 2D Array.cpp
2022. Convert 1D Array Into 2D Array.cpp
203. Remove Linked List Elements.cpp
203. Remove Linked List Elements.cpp
2032. Two Out of Three.cpp
2032. Two Out of Three.cpp
2053. Kth Distinct String in an Array.cpp
2053. Kth Distinct String in an Array.cpp
2057. Smallest Index With Equal Value.cpp
2057. Smallest Index With Equal Value.cpp
206. Reverse Linked List.cpp
206. Reverse Linked List.cpp
2068. Check Whether Two Strings are Almost Equivalent.cpp
2068. Check Whether Two Strings are Almost Equivalent.cpp
2078. Two Furthest Houses With Different Colors.cpp
2078. Two Furthest Houses With Different Colors.cpp
2089. Find Target Indices After Sorting Array.cpp
2089. Find Target Indices After Sorting Array.cpp
2095. Delete the Middle Node of a Linked List.cpp
2095. Delete the Middle Node of a Linked List.cpp
21. Merge Two Sorted Lists.cpp
21. Merge Two Sorted Lists.cpp
2108. Find First Palindromic String in the Array.cpp
2108. Find First Palindromic String in the Array.cpp
2114. Maximum Number of Words Found in Sentences.cpp
2114. Maximum Number of Words Found in Sentences.cpp
2119. A Number After a Double Reversal.cpp
2119. A Number After a Double Reversal.cpp
2124. Check if All A's Appears Before All B's.cpp
2124. Check if All A's Appears Before All B's.cpp
2129. Capitalize the Title.cpp
2129. Capitalize the Title.cpp
2138. Divide a String Into Groups of Size k.cpp
2138. Divide a String Into Groups of Size k.cpp
2154. Keep Multiplying Found Values by Two.cpp
2154. Keep Multiplying Found Values by Two.cpp
2164. Sort Even and Odd Indices Independently.cpp
2164. Sort Even and Odd Indices Independently.cpp
2169. Count Operations to Obtain Zero.cpp
2169. Count Operations to Obtain Zero.cpp
View all files
Repository files navigation
README
More
items
Leetcode
Solutions for leetcode questions.
About
Solutions for leetcode questions.
Resources
Readme
Activity
Stars
2
stars
Watchers
1
watching
Forks
0
forks
Report repository
Releases
Packages
Contributors
Languages
You can’t perform that action at this time.