Notes for Vanderbilt University
read x
while x != 1:
if isOdd(x):
x = 3x + 1
else:
x /= 2
A(m, n) =
n + 1 if m = 0
A(m - 1, 1) if m > 0 and n = 0
A(m - 1, A(m, n - 1)) if m > 0 and n > 0