1 条题解

  • 0
    @ 2026-10-2 2:21:26

    C++ :

    #include<iostream>
    #include<cmath>//pow()函数需调用<cmath>
    using namespace std;
    int main()
    {
    	int n,result;
    	cin>>n;
    	result=pow(2,n);//power(x,y),求x^y,其中x为底数,y为指数
    	cout<<result<<endl;
    	return 0;
    }
    
    • 1

    信息

    ID
    3713
    时间
    1000ms
    内存
    128MiB
    难度
    (无)
    标签
    递交数
    0
    已通过
    0
    上传者