[Haskell-beginners] Lambda calc version of Haskell lambda function
Lawrence Bottorff
borgauf at gmail.com
Fri Jan 1 04:33:36 UTC 2021
Here is a function declaration
makeAddress :: Int -> String -> String -> (Int, String, String)
makeAddress number street town = (number,street,town)
and here is a lambda function version
makeAddressLambda = (\number -> (\street -> (\town -> (number, street,
town))))
How would this lambda version look in lambda calculus? Like this?
\number.\street.\town.(number street town)
then
(\number.\street.\town.(number street town) (123 "Sunny St." "Fergus")
(\street.\town.(123 street town) ("Sunny St." "Fergus")
(\town.(123 "Sunny St.") ("Fergus")
(123 "Sunny St." "Fergus")
Not always sure.
LB
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/beginners/attachments/20201231/34ec6fe3/attachment.html>
More information about the Beginners
mailing list