Currying: Difference between revisions
Content deleted Content added
→{{header|Visual Basic .NET}}: Added VB.NET |
added Ol |
||
Line 1,248: | Line 1,248: | ||
5 2+ . |
5 2+ . |
||
7 ok</lang> |
7 ok</lang> |
||
=={{header|Ol}}== |
|||
<lang scheme> |
|||
(define (addN n) |
|||
(lambda (x) (+ x n))) |
|||
(let ((add10 (addN 10)) |
|||
(add20 (addN 20))) |
|||
(print "(add10 4) ==> " (add10 4)) |
|||
(print "(add20 4) ==> " (add20 4))) |
|||
</lang> |
|||
{{out}} |
|||
<pre> |
|||
(add10 4) ==> 14 |
|||
(add20 4) ==> 24 |
|||
</pre> |
|||
=={{header|PARI/GP}}== |
=={{header|PARI/GP}}== |