Philips interview question

Fibonacci serie