<?php
class TodoFullSmallFibonacciObject
{
    private function fibonacci(int $n): int
    {
        if ($n <= 1) {
            return $n;
        }

        $n2 = 0;
        $n1 = 1;

        for ($i = 2; $i < $n; $i++) {
            $n2_ = $n2;
            $n2 = $n1;
            $n1 = ($n1 + $n2_);
        }

        return $n2 + $n1;
    }

    public function run(): int
    {
        return $this->fibonacci(10);
    }
}

$obj = new TodoFullSmallFibonacciObject();
echo $obj->run() . "\n";
