#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int n;
cin >> n;
cout << "2^" << n << " = " << pow(2, n);
return 0;
}
团体程序设计天梯赛-练习集 L1-012 计算指数 (5分)
最新推荐文章于 2024-03-07 11:49:53 发布
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int n;
cin >> n;
cout << "2^" << n << " = " << pow(2, n);
return 0;
}