#include <iostream>
#include <vector>
using namespace std;
#define int long long
signed main() {
ios_base::sync_with_stdio(false);
cin.tie(nullptr);
cout.tie(nullptr);
int a;
cin >> a;
int cur = 0;
string s = "";
for (size_t i = 0; i < a; i++)
{
cur/=10;
int b;
cin >> b;
cur+=b;
//cout << cur << "\n";
}
int tV = 1;
for (size_t i = 0; i < 18; i++)
{
if(tV>cur) {
cur=cur-(cur%(tV/10));
break;
}
tV*=10;
}
for (size_t i = 0; i < a-1; i++)
{
s+='0';
}
cout << cur << s << "\n";
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 1836 KiB | ||||
2 | Accepted | 3ms | 2056 KiB | ||||
3 | Accepted | 3ms | 2256 KiB | ||||
subtask2 | 0/25 | ||||||
4 | Runtime error | 3ms | 2420 KiB | ||||
5 | Runtime error | 3ms | 2548 KiB | ||||
6 | Runtime error | 3ms | 2632 KiB | ||||
7 | Runtime error | 3ms | 2600 KiB | ||||
8 | Runtime error | 3ms | 3008 KiB | ||||
subtask3 | 0/26 | ||||||
9 | Runtime error | 3ms | 3024 KiB | ||||
10 | Runtime error | 3ms | 3152 KiB | ||||
11 | Runtime error | 3ms | 3108 KiB | ||||
12 | Runtime error | 3ms | 3112 KiB | ||||
13 | Runtime error | 3ms | 3108 KiB | ||||
14 | Accepted | 3ms | 3132 KiB | ||||
15 | Accepted | 3ms | 3132 KiB | ||||
16 | Accepted | 3ms | 3368 KiB | ||||
subtask4 | 0/19 | ||||||
17 | Wrong answer | 3ms | 3632 KiB | ||||
18 | Wrong answer | 3ms | 3568 KiB | ||||
19 | Wrong answer | 3ms | 3668 KiB | ||||
20 | Wrong answer | 3ms | 3828 KiB | ||||
subtask5 | 0/30 | ||||||
21 | Wrong answer | 23ms | 6336 KiB | ||||
22 | Wrong answer | 23ms | 8300 KiB | ||||
23 | Wrong answer | 23ms | 10168 KiB | ||||
24 | Wrong answer | 21ms | 11976 KiB | ||||
25 | Wrong answer | 23ms | 13724 KiB | ||||
26 | Wrong answer | 23ms | 15868 KiB | ||||
27 | Accepted | 14ms | 16728 KiB | ||||
28 | Wrong answer | 3ms | 16476 KiB |