|
- \ifger{Wie am Anfang dieses Kapitels bereits gesagt sind diese beiden Funktionen sehr ähnlich:}{As said in the beginning of this section, these two look pretty similar:}
- \begin{haskellcode}
- f :: Int -> Int -> Int
-
- f :: (Int, Int) -> Int
- \end{haskellcode}
- \ifger{Da wir jetzt wissen, dass man von der einen Form in die andere und zurück konvertieren kann, müssten wir dann nicht auch Funktionen dafür haben? Haben wir:}{And we now know that we can convert from one to another. Of course haskell also provides us two functions to do that, here we go:}
- \begin{haskellcode}
- curry :: ((a, b) -> c) -> a -> b -> c
-
- uncurry :: (a -> b -> c) -> (a, b) -> c
- \end{haskellcode}
|