Initial implementation for challenge 1 to 9