Consolation prize: FreeBasic can't do any better! http://www.rosettacode.org/wiki/Ackerman...#FreeBASIC
Code: (Select All)
_Define A-Z As _UNSIGNED _INTEGER64
Print
Print "Ackermann"
Print
For m = 0 To 4
For n = 0 To 10
If m = 4 And n > 0 Then Exit For 'bug out this is as far as FreeBasic gets at RC
Print Using "######"; ackermann(m, n);
Next
Print
Next
Function ackermann (m, n)
If m = 0 Then
ackermann = n + 1
ElseIf m > 0 And n = 0 Then
ackermann = ackermann(m - 1, 1)
ElseIf m > 0 And n > 0 Then
ackermann = ackermann(m - 1, ackermann(m, n - 1))
End If
End Function
b = b + ...