| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 1356670 | Aviansh | Flooding Wall (BOI24_wall) | C++20 | 35 ms | 8180 KiB |
#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9+7;
signed main(){
ios::sync_with_stdio(0);
cin.tie(0);
int n;
cin >> n;
int a[n],b[n];
for(int &i : a){
cin >> i;
}
for(int &i : b){
cin >> i;
}
long long po[n];
po[0]=1;
for(int i = 1;i<n;i++){
po[i]=po[i-1]*2;
po[i]%=mod;
}
long long ans = 0;
for(int i = 0;i<n;i++){
ans+=(po[i]-1)*(po[n-i-1]-1);
ans%=mod;
}
cout << ans;
return 0;
}
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
