الرجوع
تسجيل الدخول
أنت تتصفح نسخة مؤرشفة من الموقع اضغط للانتقال إلى الموقع الجديد بكامل المزايا

Given the following method declaration, what value is returned as the result of the call f(5)?

public static int f(int n)
{
   if (n == 0)
      return 0;
   else if (n == 1)
      return 1;
   else return f(n-1) + f(n-2);
}