Domanda di colloquio di Rackspace Technology

Can you write the code to generate the Fibonacci sequence?

Risposte di colloquio

Anonimo

28 mar 2012

HI, Thank you so much for posting this. I am going to have interview with Rack space for Linux system administrator Position. Can you please provide some question that has been asked by them so it will help me prepare for the interview. Thanks, Vishal

Anonimo

4 set 2012

My impulse is to use a temporary value holder as well, but I've seen a more elegant solution (in python). It's so pretty... l = 0 n = 1 print l for i in range(100): print n n = n + l l = n - l

Anonimo

17 nov 2013

the best way is to use recursive call.. but if i was asked..i will probably end up with this def fab(): x = 0 y = 1 while y < 100: print x print y x += y y += x fab()