William Hill interview question

Implement the curry and uncurry function