News for hackers. Stuff that matters.
Re:What is the coolest thing you can do in ten lines of code? by spc476 on Friday December 30, 2011 @08:45PM (#3409832)
In Lua:

  function Y(f)
    local function g(...) return f(g,...) end
    return g
  end

  print(Y(function(rec,x)
            if x < 2 then
              return 1
            else
              return x * rec(x-1)
            end
           end)(5))

There are no comments on this comment yet.