the code that solve some leetcode problems