Leonardo Fibonacci is mostly known for the fibonacci sequence (0, 1, 1, 2, 3, 5, 8, 13, ...).

learn more… | top users | synonyms

11
votes
6answers
1k views

Fibonacci program lengths

Write a program with length n that outputs another program whose length is the next Fibonacci number after n. The new program must do the same thing - output another program whose length is the next ...
2
votes
1answer
338 views

Fibonacci is so QUINE!

Your program must output atleast half of its sourcecode in reverse. Any single part of the sourcecode as long as it is one single block of neighbouring characters. Your program should not take any ...
8
votes
8answers
294 views

Fibonacci distribution validator

Related: Hello world!!! Fibonacci distribution Create a program that returns True if a given input meets the following specifications, and False otherwise: The count of numeric characters (0-9) ...
4
votes
4answers
133 views

Quine with prime sourcecode character distribution constraints

Your program should take no input, and no network or other connections. Your program should output it's sourcecode. The sourcecode must consist of 3 types of characters: Numeric (0-9), Alpha ...
17
votes
19answers
3k views

Hello world!!! Fibonacci distribution

Your program should output exactly: Hello world!!! with or without linefeed after. Your program should take no input. Sourcecode character distribution must be correct according to: The number of ...
8
votes
8answers
575 views

Write a Number as a Fibonacci Sum

Let us define the Fibonacci sequence as F(1)=1 F(2)=2 F(n)=F(n-2)+F(n-1) So we have the infinite sequence 1,2,3,5,8,13,... It is well known that any positive integer can be written as a sum of ...
8
votes
14answers
927 views

FIBonacci sequence

For this code golf, you will receive an input of a fibonacci sequence, that is, a normal Fibonacci sequence but with one number incorrect. See, the sequence is fibbing! Get it? :D Your job is to find ...
10
votes
7answers
1k views

Find the Pisano Period of a number

Input: An integer 0 < n < 2^30, taken from stdin. Output: The Pisano period of n (the length of the cycle of the Fibonacci sequence mod n) Input is smaller than 2^30 so that intermediate ...
6
votes
9answers
1k views

Find the nth Fibonnaci Prime, in the shortest code

The challenge is rather simple: Take a positive whole number n as input. Output the nth Fibonacci prime number. Input can be as an parameter to a function (and the output will be the return ...
6
votes
24answers
2k views

code-golf: First-n Fibonacci sequence elements

There is a well known question here that asks for a short (least characters) fibonacci sequence generator. I would like to know if someone can generate the first N elements only, of the fibonacci ...
8
votes
12answers
2k views

Write the fastest Fibonacci

This is yet another challenge about the Fibonacci numbers. The goal is to compute the 20'000'000th Fibonacii number as fast as possible. The decimal output is about 4 MiB large; it starts with: ...
11
votes
12answers
1k views

The minimum fibonacci challenge!

Challenge In this task you would be given an integer N (less than 10^6), find the minimum way in which you could sum to N using only Fibonacci numbers. You could any Fibonacci number more ...
2
votes
4answers
908 views

Sum of Fibonacci numbers — speed contest

Write a program that print sum of as many Fibonacci numbers as possible. There is a limit in that your program should not run more than 10s on 2GHz single core PC. (equivalents are acceptable, for ...
8
votes
6answers
660 views

What is the average of n, the closest prime to n, the square of n and the closest fibbonacci number to n?

This is a math problem which takes quite many things into question, making it rather challenging, and as you might have guessed, it's a code golf, so it should be as short as possible as well. The ...
3
votes
3answers
521 views

Sum of Fibonacci numbers

I found this task here. Given the ith (1<=i<=35) Fibonacci number F(i) calculate the sum of the ith till i+9th number F(i)+F(i+1)+...+F(i+9) and the last digit of the i+246th one ...
37
votes
67answers
5k views

Fibonacci function or sequence

Write the shortest code that either: Generates a Fibonacci sequence (either in standard output, or as a stream) Calculates, given n, the nth Fibonacci number (I gave both options in case one is ...
150
votes
57answers
8k views

Fibonacci Sequence Generator

Can you create a clever or unexpected Fibonacci generator? Your code must print or return either the nth Fibonacci number or the first n Fibonacci numbers.