Submission #945106

# Submission time Handle Problem Language Result Execution time Memory
945106 2024-03-13T12:06:56 Z Reverberate Fancy Fence (CEOI20_fancyfence) C++17
0 / 100
1 ms 348 KB
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define double long double
#define INF 1e18
#define DEBUG 0
#define MOD (int)(1e9 + 6)

signed main(){
	ios_base::sync_with_stdio(0);
	cin.tie(0);
	int n, W = 0, H = 0; cin >> n;
	
	for(int i = 0; i < n; i++){
		int h; cin >> h;
		H = h;
	}
	for(int i = 0; i < n; i++){
		int w; cin >> w;
		W += w;
	}
	int temp = (H*(H+1));
	temp /= 2;
	temp %= MOD;
	int temp2 = (W*(W+1));
	temp2 /= 2;
	temp2 %= MOD;
	int temp3 = (temp*temp2);
	temp3 %= MOD;
	cout << temp3;
}
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 348 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 348 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -