#27439: __解答


yp10952161@yphs.tp.edu.tw (無)


#include <iostream>

using namespace std;

/* run this program using the console pauser or add your own getch, system("pause") or input loop */

int f91(int n)

{

if(n>=101) return n-10;

else f91(f91(n+11));

}

int main() {

int n;

while(cin>>n, n!=0)

     cout<<"f91(" << n <<") = " << f91(n) <<endl;

 

 

}