diff --git a/Unit 1/Lesson 4/firstClassFunctions.hs b/Unit 1/Lesson 4/firstClassFunctions.hs index f363d32..4e4be99 100644 --- a/Unit 1/Lesson 4/firstClassFunctions.hs +++ b/Unit 1/Lesson 4/firstClassFunctions.hs @@ -10,10 +10,11 @@ isEven myFunction x = if even x then myFunction x else x - ifEvenDouble :: Integral p => p -> p ifEvenDouble x = isEven double x ifEvenInc :: Integral p => p -> p ifEvenInc x = isEven inc x ifEvenSquare :: Integral p => p -> p -ifEvenSquare x = isEven square x \ No newline at end of file +ifEvenSquare x = isEven square x +ifEvenCube :: Integral a => a -> a +ifEvenCube x = isEven (\x -> x ^ 3) x \ No newline at end of file