File:  [CSRG BSD Unix] / 43BSD / contrib / icon / book / f / acker2.icn
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 16:12:55 2018 UTC (8 years, 1 month ago) by root
Branches: MAIN, BSD
CVS tags: HEAD, BSD43
BSD 4.3

procedure acker(i,j)
   local args, k
   static ackermem
   initial ackermem := table()
   args := i || "," || j
   if k := \ackermem[args] then return k
   if i = 0 then return ackermem[args] := j + 1
   if j = 0 then return ackermem[args] := acker(i - 1,1)
   return ackermem[args] := acker(i - 1,acker(i,j - 1))
end

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.