0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-12-03 19:16:27 +00:00

749. 数组的上方区域

https://www.acwing.com/problem/content/submission/code_detail/14063225/
This commit is contained in:
Baoshuo Ren 2022-05-09 18:49:01 +08:00
parent 39b812e23c
commit d8a111de8e
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68
3 changed files with 24 additions and 0 deletions

18
AcWing/749/749.cpp Normal file
View File

@ -0,0 +1,18 @@
#include <bits/stdc++.h>
using namespace std;
int main() {
char op;
cin >> op;
double x, sum = 0;
for (int i = 0; i < 12; i++) {
for (int j = 0; j < 12; j++) {
cin >> x;
if (i < 5 && j > i && j <= 10 - i) sum += x;
}
}
cout << fixed << setprecision(1) << sum / (op == 'S' ? 1 : 30) << endl;
return 0;
}

BIN
AcWing/749/data/6.ans (Stored with Git LFS) Normal file

Binary file not shown.

BIN
AcWing/749/data/6.in (Stored with Git LFS) Normal file

Binary file not shown.