Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on ... because Ruby isn't terse enough yet. Parent comment
Foo = fun(N) -> put(var, N), fun(X) -> V = get(var) + X, put(var, V), V end end.
It's not as concise as Ruby or Arc, but it's a one liner. However, similar to Haskell, this style of programming is discouraged in Erlang.
There are no comments on this comment yet.
Foo = fun(N) -> put(var, N), fun(X) -> V = get(var) + X, put(var, V), V end end.
It's not as concise as Ruby or Arc, but it's a one liner. However, similar to Haskell, this style of programming is discouraged in Erlang.