From 5fc792d17b68e2c4caaa7d583df1254ca36619f2 Mon Sep 17 00:00:00 2001 From: Nicolas Schweitzer Date: Tue, 7 Jul 2026 20:37:30 +0000 Subject: [PATCH] test: validate ai-review.yml@main invocation end-to-end (buggy fibo) --- fibonacci.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 fibonacci.py diff --git a/fibonacci.py b/fibonacci.py new file mode 100644 index 0000000..8392e0e --- /dev/null +++ b/fibonacci.py @@ -0,0 +1,16 @@ +def fibonacci(n): + """Return the n-th term of the Fibonacci sequence (0-indexed).""" + if n < 0: + raise ValueError("n must be a non-negative integer") + if n == 0: + return 0 + + a, b = 0, 1 + for _ in range(n - 1): + a, b = b, a + b + return a + + +if __name__ == "__main__": + for i in range(10): + print(f"fibonacci({i}) = {fibonacci(i)}")