Skip to content

Leetcode solutions in C++, C#, Python, Java, Scala, JS, Kotlin, Go, etc

Notifications You must be signed in to change notification settings

lijiayi0921/Leetcode-1

 
 

Repository files navigation

LeetCode

https://leetcode.com

June LeetCoding Challenge

Click here for problem descriptions.

Solutions in various programming languages are provided. Enjoy it.

  1. Invert Binary Tree: Tree Traversal
  2. Delete Node in a Linked List: Linked List
  3. Two City Scheduling: DP

May LeetCoding Challenge

Click here for problem descriptions.

Solutions in various programming languages are provided. Enjoy it.

  1. First Bad String: Binary search.
  2. Jewels and Stones: Hash Table
  3. Ransom Note: Hash Table
  4. Number Complement: Bitwise Manipulation
  5. First Unique Character In a String: Hash Table
  6. Majority Element: Ad hoc
  7. Cousins in Binary Tree: BFS / Recursion
  8. Check if it is straight line: Cross Product
  9. Valid Perfect Square: Math
  10. Find the Town Judge: Graph Theory
  11. Flood Fill: BFS
  12. Single Element In a Sorted Array: Binary Search
  13. Remove K Digits: Greedy
  14. Implement Trie: Trie
  15. Maximum Sum Circular Subarray: DP
  16. Odd Even Linked List: Linked List
  17. Find All Anagrams in a String: Sliding window + Hash Table
  18. Permutation In String: Sliding window + Hash Table
  19. Online Stock Span: DP
  20. Kth-Smallest-Element-In-A-BST: BST
  21. Count Square Submatrices with All Ones: DP
  22. Sort Characters By Frequency: Hash Table
  23. Interval List Intersections: Two Pointers
  24. Construct Binary Search Tree from Preorder Traversal: Binary Search Tree
  25. Uncrossed Lines: DP
  26. Contiguous Array: Hash Table
  27. Possible Bipartition: Bipartite Graph
  28. Counting Bits: Math
  29. Course Schedule: Topological Sort
  30. K Closest Points to Origin: Priority_queue, Sort
  31. Edit Distance: DP

30-Day (April) LeetCoding Challenge

Click here for problem descriptions.

  1. Single Number: Bitwise Manipulation
  2. Happy Number: Implementation
  3. Maximum Subarray: DP
  4. Move Zeros: Two pointers
  5. Best Time to Buy and Sell Stock II: Greedy
  6. Group Anagrams: Hash Table

About

Leetcode solutions in C++, C#, Python, Java, Scala, JS, Kotlin, Go, etc

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Kotlin 28.8%
  • Java 23.7%
  • C++ 16.0%
  • Scala 14.4%
  • Python 7.2%
  • JavaScript 4.8%
  • Other 5.1%