Solutions to Paul Graham's Accumulator Generator In Various Languages
Java Clojure Ruby
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
accgen.clj Updated clojure solution to use atom Dec 23, 2008


This is a collection of implementations of Paul Graham's Accumulator Generator. The problem is:

The problem: Write a function foo that takes a number n and returns a function that takes a number i, and returns n incremented by i.

Note: (a) that's number, not integer, (b) that's incremented by, not plus.