#include <stdio.h>
char *input_1 = "11"; // al posto di argv[1];
unsigned int
fibonacci (unsigned int n)
{
unsigned int f1 = 1;
unsigned int f0 = 0;
unsigned int fn = n;
unsigned int i;
for (i = 2; i <= n; i++)
{
fn = f1 + f0;
f0 = f1;
f1 = fn;
}
return fn;
}
int
main (int argc, char *argv[])
{
unsigned int n;
unsigned int i;
for (i = 0; i <= n; i++)
{
printf ("%u ", fibonacci
(i
)); }
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CgpjaGFyICppbnB1dF8xID0gIjExIjsgIC8vIGFsIHBvc3RvIGRpIGFyZ3ZbMV07Cgp1bnNpZ25lZCBpbnQKZmlib25hY2NpICh1bnNpZ25lZCBpbnQgbikKewogICAgdW5zaWduZWQgaW50IGYxID0gMTsKICAgIHVuc2lnbmVkIGludCBmMCA9IDA7CiAgICB1bnNpZ25lZCBpbnQgZm4gPSBuOwogICAgdW5zaWduZWQgaW50IGk7CgogICAgZm9yIChpID0gMjsgaSA8PSBuOyBpKyspCiAgICAgIHsKICAgICAgICBmbiA9IGYxICsgZjA7CiAgICAgICAgZjAgPSBmMTsKICAgICAgICBmMSA9IGZuOwogICAgICB9CgogICAgcmV0dXJuIGZuOwp9CgppbnQKbWFpbiAoaW50IGFyZ2MsIGNoYXIgKmFyZ3ZbXSkKewogICAgdW5zaWduZWQgaW50IG47CiAgICB1bnNpZ25lZCBpbnQgaTsKCiAgICBzc2NhbmYgKGlucHV0XzEsICIldSIsICZuKTsKCiAgICBmb3IgKGkgPSAwOyBpIDw9IG47IGkrKykKICAgICAgewogICAgICAgIHByaW50ZiAoIiV1ICIsIGZpYm9uYWNjaSAoaSkpOwogICAgICB9CiAgICBwcmludGYgKCJcbiIpOwoKICAgIHJldHVybiAwOwp9