Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
97061 杨一诺 x的n次方 C++ Accepted 1 MS 272 KB 273 2024-11-10 12:01:09

Tests(10/10):


Code:

#include<bits/stdc++.h> using namespace std; int sum; long long x,y; long long age(long long a,long long b){ if(b==1){ return a; } else if(b==0){ return 1; } else{ return age(a,b-1)*a; } } int main(){ cin>>x>>y; cout<<age(x,y); return 0; }