Coding challenge

Use a for-loop and a print statement to show that if $a_1=1$, then the terms of this sequence $a_{n+1}=2a_n+\sqrt{3a_n^2-2}$ are integers. (From Andreescu p. 83, #11.)

Type your code here:


Lua reference

See your results here: