文章
25
粉丝
137
获赞
7
访问
129.2k
#include<iostream>
#include<cmath>
using namespace std;
int main()
{
int n, num[1001], i, deep;
cin >> n;
for (i = 1; i <= n; ++i)
cin >> num[i];
cin >> deep;
int len = pow(2, deep - 1), start = len;
for (; start <= len + len - 1 && start <= n; ++start) {
cout << num[start] << " ";
}
}
登录后发布评论
暂无评论,来抢沙发