Fibonacci in Boo

Published on 02 October 2020 (Updated: 13 November 2023)

Welcome to the Fibonacci in Boo page! Here, you'll find the source code for this program as well as a description of how the program works.

Current Solution

import System

def usage():
    print("Usage: please input the count of fibonacci numbers to output")
    Environment.Exit(0)

def fib(n):
    a, b = 0L, 1L       # The 'L's make the numbers double word length (typically 64 bits)
    for index in range(n):
        yield index + 1, b
        a, b = b, a + b

# Print the first n numbers in the series:
try:
    n = int.Parse(argv[0])
    for index as int, element in fib(n):
        print("${index}: ${element}")
except _ as IndexOutOfRangeException:
    usage()
except _ as FormatException:
    usage()

Fibonacci in Boo was written by:

If you see anything you'd like to change or update, please consider contributing.

How to Implement the Solution

No 'How to Implement the Solution' section available. Please consider contributing.

How to Run the Solution

No 'How to Run the Solution' section available. Please consider contributing.