solved 114 with a simple recursive top down approach