Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
68639 何睿哲 x的n次方 C++ Accepted 1 MS 276 KB 196 2024-03-24 10:21:17

Tests(10/10):


Code:

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