This repository contains implementations or code segments of some classic data structures, algorithms and solutions of LeetCode questions.
- [C#] BubbleSortHelper
- [C#] MergingSortHelper
- [C#] QuickSortHelper
- [C#] InsertionSortHelper
- [C#] SelectionSortHelper
- [C#] Link list definication
- [C#] Reverse logic
LeetCode No.1 question: Two Sum
- [C#] Solution
- [C#] Official Answer
LeetCode No.2 question: Add Two Numbers
- [C#] Solution, the solution is INCORRECT since it cannot handle the big number, but I still keep it
- [C#] Official Answer
LeetCode No.3 question: Longest Substring without Repeating Characters
- [C#] Solution
- [C#] Official Answer
LeetCode No.4 question: Median of Two Sorted Arrays
- [C#] Solution A
- [C#] Solution B
- [C#] Official Answer A
- [C#] Official Answer B
LeetCode No.5 question: Longest Palindrome Substring
- [C#] Solution
- [C#] Official Answer A
- [C#] Official Answer B
- [C#] Official Answer C
LeetCode No.7 question: Reverse Integer
- [C#] Solution
- [C#] Official Answer
LeetCode No.8 question: String to Integer (atoi)
- [C#] Solution
- [C#] Official Answer
LeetCode No.9 question: Palindrome Number
- [C#] Solution
- [C#] Official Answer
LeetCode No.15 question: Three Sum
- [C#] Solution, the result is correct however the performance is very poor
- [C#] Official Answer
LeetCode No.16 question: Three Sum Closest
- [C#] Solution, the result is correct however the performance is very poor
- [C#] Official Answer
LeetCode No.17 question: Letter Combinations of a Phone Number
- [C#] Solution
- [C#] Official Answer
LeetCode No.18 question: Four Sum
- [C#] Solution, the result is correct however the performance is not good enough
- [C#] Official Answer
LeetCode No.20 question: Valid Parentheses
- [C#] Solution, the solution is as same as the official answer
- [C#] Official Answer
LeetCode No.21 question: Merge Two Sorted Lists
- [C#] Solution
- [C#] Official Answer
- [C#] Test Case, it costs a while to pass the unit test since I was blocked by pointer of linked list.
LeetCode No.23 question: Merge K Sorted Lists
- [C#] Solution A
- [C#] Solution B
- [C#] Official Answer A
- [C#] Official Answer B
- [C#] Official Answer C, this answer uses PriorityQueue, and PriorityQueue is just supported in .NET 6.