---------------------------------------------------------------------- This is the API documentation for the gdtest_docstring_examples library. ---------------------------------------------------------------------- ## Functions Public functions fibonacci(n: int) -> list Generate the first n Fibonacci numbers. Computes the Fibonacci sequence starting from 0 and returns a list of the first ``n`` values. Parameters ---------- n The number of Fibonacci values to generate. Must be a positive integer. Returns ------- list A list of the first ``n`` Fibonacci numbers. Raises ------ ValueError If ``n`` is less than 1. Examples -------- >>> fibonacci(5) [0, 1, 1, 2, 3] >>> fibonacci(1) [0] You can also use it with larger values: >>> len(fibonacci(100)) 100 Edge case with exactly two values: >>> fibonacci(2) [0, 1] factorial(n: int) -> int Compute the factorial of a non-negative integer. Returns the product of all positive integers less than or equal to ``n``. By convention, ``factorial(0)`` is 1. Parameters ---------- n A non-negative integer whose factorial is to be computed. Returns ------- int The factorial of ``n``. Raises ------ ValueError If ``n`` is negative. Examples -------- >>> factorial(5) 120 >>> factorial(0) 1 Factorials grow very quickly: >>> factorial(10) 3628800 >>> factorial(20) 2432902008176640000 Works with small values too: >>> factorial(1) 1 >>> factorial(2) 2