mirror of
https://git.sb/baoshuo/OI-codes.git
synced 2024-11-27 14:56:27 +00:00
749. 数组的上方区域
https://www.acwing.com/problem/content/submission/code_detail/14063225/
This commit is contained in:
parent
39b812e23c
commit
d8a111de8e
18
AcWing/749/749.cpp
Normal file
18
AcWing/749/749.cpp
Normal 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
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
BIN
AcWing/749/data/6.in
(Stored with Git LFS)
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user