Solutions to LeetCode problems