added higher order functions, added dependency on numeric-tower