Yeah, I know it's boring.
When I have free time I solve leetcode problems. My language of choice is C, although that can change in the future. My compiler of choice is clang
.
All code is compiled with the following flags:
Just call ./run.sh
passing the exercise name (i.e. its folder) as argument.
Example:
./run.sh climbing-stairs
The folders are usually displayed in alphabetical order by your file system. Here's the list as per LeetCode's index order:
- 1. Two Sum
- 13. Roman To Integer
- 14. Longest Common Prefix
- 20. Valid Parentheses
- 21. Merge Two Sorted Lists
- 26. Remove Duplicates from Sorted Array
- 28. Implement strStr()
- 66. Plus One
- 69. Sqrt(x)
- 70. Climbing Stairs
- 88. Merge Sorted Array
- 94. Binary Tree Inorder Traversal
- 101. Symmetric Tree
- 104. Maximum Depth of Binary Tree
- 118. Pascal's Triangle
- 412. Fizz Buzz