mirror of
https://github.com/thma/WhyHaskellMatters.git
synced 2024-09-11 13:46:11 +03:00
remove misplaced reference to even
This commit is contained in:
parent
adb738b335
commit
7d80675139
@ -329,8 +329,7 @@ The Haskell code is straightforward: new ingredients are the `if ... then ... el
|
|||||||
odd `odd` which is a predicate from the Haskell standard library
|
odd `odd` which is a predicate from the Haskell standard library
|
||||||
that returns `True` if an integral number is odd.
|
that returns `True` if an integral number is odd.
|
||||||
|
|
||||||
Now let's assume that we also need another function that computes the square for any odd number.
|
Now let's assume that we also need another function that computes the square for any odd number:
|
||||||
As you can imagine we can use the standard library predicate `even`:
|
|
||||||
|
|
||||||
```haskell
|
```haskell
|
||||||
ifOddSquare :: Integer -> Integer
|
ifOddSquare :: Integer -> Integer
|
||||||
|
Loading…
Reference in New Issue
Block a user