coding practices - my solutions for problems from http://leetcode.com