QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#713852 | #1880. Nikanor Loves Games | maspy | AC ✓ | 82ms | 30936kb | C++23 | 15.7kb | 2024-11-05 20:42:32 | 2024-11-05 20:42:32 |
Judging History
answer
#line 1 "library/my_template.hpp"
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pi = pair<ll, ll>;
using vi = vector<ll>;
using u32 = unsigned int;
using u64 = unsigned long long;
using i128 = __int128;
template <class T>
using vc = vector<T>;
template <class T>
using vvc = vector<vc<T>>;
template <class T>
using vvvc = vector<vvc<T>>;
template <class T>
using vvvvc = vector<vvvc<T>>;
template <class T>
using vvvvvc = vector<vvvvc<T>>;
template <class T>
using pq = priority_queue<T>;
template <class T>
using pqg = priority_queue<T, vector<T>, greater<T>>;
#define vec(type, name, ...) vector<type> name(__VA_ARGS__)
#define vv(type, name, h, ...) \
vector<vector<type>> name(h, vector<type>(__VA_ARGS__))
#define vvv(type, name, h, w, ...) \
vector<vector<vector<type>>> name( \
h, vector<vector<type>>(w, vector<type>(__VA_ARGS__)))
#define vvvv(type, name, a, b, c, ...) \
vector<vector<vector<vector<type>>>> name( \
a, vector<vector<vector<type>>>( \
b, vector<vector<type>>(c, vector<type>(__VA_ARGS__))))
// https://trap.jp/post/1224/
#define FOR1(a) for (ll _ = 0; _ < ll(a); ++_)
#define FOR2(i, a) for (ll i = 0; i < ll(a); ++i)
#define FOR3(i, a, b) for (ll i = a; i < ll(b); ++i)
#define FOR4(i, a, b, c) for (ll i = a; i < ll(b); i += (c))
#define FOR1_R(a) for (ll i = (a)-1; i >= ll(0); --i)
#define FOR2_R(i, a) for (ll i = (a)-1; i >= ll(0); --i)
#define FOR3_R(i, a, b) for (ll i = (b)-1; i >= ll(a); --i)
#define FOR4_R(i, a, b, c) for (ll i = (b)-1; i >= ll(a); i -= (c))
#define overload4(a, b, c, d, e, ...) e
#define FOR(...) overload4(__VA_ARGS__, FOR4, FOR3, FOR2, FOR1)(__VA_ARGS__)
#define FOR_R(...) \
overload4(__VA_ARGS__, FOR4_R, FOR3_R, FOR2_R, FOR1_R)(__VA_ARGS__)
#define FOR_subset(t, s) for (ll t = s; t >= 0; t = (t == 0 ? -1 : (t - 1) & s))
#define all(x) x.begin(), x.end()
#define len(x) ll(x.size())
#define elif else if
#define eb emplace_back
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second
#define stoi stoll
template <typename T>
T SUM(vector<T> &A) {
T sum = T(0);
for (auto &&a: A) sum += a;
return sum;
}
#define MIN(v) *min_element(all(v))
#define MAX(v) *max_element(all(v))
#define LB(c, x) distance((c).begin(), lower_bound(all(c), (x)))
#define UB(c, x) distance((c).begin(), upper_bound(all(c), (x)))
#define UNIQUE(x) sort(all(x)), x.erase(unique(all(x)), x.end())
int popcnt(int x) { return __builtin_popcount(x); }
int popcnt(u32 x) { return __builtin_popcount(x); }
int popcnt(ll x) { return __builtin_popcountll(x); }
int popcnt(u64 x) { return __builtin_popcountll(x); }
// (0, 1, 2, 3, 4) -> (-1, 0, 1, 1, 2)
int topbit(int x) { return (x == 0 ? -1 : 31 - __builtin_clz(x)); }
int topbit(u32 x) { return (x == 0 ? -1 : 31 - __builtin_clz(x)); }
int topbit(ll x) { return (x == 0 ? -1 : 63 - __builtin_clzll(x)); }
int topbit(u64 x) { return (x == 0 ? -1 : 63 - __builtin_clzll(x)); }
// (0, 1, 2, 3, 4) -> (-1, 0, 1, 0, 2)
int lowbit(int x) { return (x == 0 ? -1 : __builtin_ctz(x)); }
int lowbit(u32 x) { return (x == 0 ? -1 : __builtin_ctz(x)); }
int lowbit(ll x) { return (x == 0 ? -1 : __builtin_ctzll(x)); }
int lowbit(u64 x) { return (x == 0 ? -1 : __builtin_ctzll(x)); }
template <typename T, typename U>
T ceil(T x, U y) {
return (x > 0 ? (x + y - 1) / y : x / y);
}
template <typename T, typename U>
T floor(T x, U y) {
return (x > 0 ? x / y : (x - y + 1) / y);
}
template <typename T, typename U>
pair<T, T> divmod(T x, U y) {
T q = floor(x, y);
return {q, x - q * y};
}
ll binary_search(function<bool(ll)> check, ll ok, ll ng) {
assert(check(ok));
while (abs(ok - ng) > 1) {
auto x = (ng + ok) / 2;
if (check(x))
ok = x;
else
ng = x;
}
return ok;
}
template <typename F>
double binary_search_real(F check, double ok, double ng, int iter = 100) {
FOR(iter) {
double x = (ok + ng) / 2;
if (check(x)) {
ok = x;
} else {
ng = x;
}
}
return (ok + ng) / 2;
}
template <class T, class S>
inline bool chmax(T &a, const S &b) {
return (a < b ? a = b, 1 : 0);
}
template <class T, class S>
inline bool chmin(T &a, const S &b) {
return (a > b ? a = b, 1 : 0);
}
vi s_to_vi(const string &S, char first_char) {
vi A(S.size());
FOR(i, S.size()) { A[i] = S[i] - first_char; }
return A;
}
template <typename T>
vector<T> cumsum(vector<T> &A, int off = 1) {
int N = A.size();
vector<T> B(N + 1);
FOR(i, N) { B[i + 1] = B[i] + A[i]; }
if (off == 0) B.erase(B.begin());
return B;
}
template <typename CNT, typename T>
vc<CNT> bincount(const vc<T> &A, int size) {
vc<CNT> C(size);
for (auto &&x: A) { ++C[x]; }
return C;
}
template <typename T>
vector<int> argsort(const vector<T> &A) {
// stable
vector<int> ids(A.size());
iota(all(ids), 0);
sort(all(ids),
[&](int i, int j) { return A[i] < A[j] || (A[i] == A[j] && i < j); });
return ids;
}
// A[I[0]], A[I[1]], ...
template <typename T>
vc<T> rearrange(const vc<T> &A, const vc<int> &I) {
int n = len(A);
assert(len(I) == n);
vc<T> B(n);
FOR(i, n) B[i] = A[I[i]];
return B;
}
#line 1 "library/other/io.hpp"
// based on yosupo's fastio
#include <unistd.h>
namespace detail {
template <typename T, decltype(&T::is_modint) = &T::is_modint>
std::true_type check_value(int);
template <typename T>
std::false_type check_value(long);
} // namespace detail
template <typename T>
struct is_modint : decltype(detail::check_value<T>(0)) {};
template <typename T>
using is_modint_t = enable_if_t<is_modint<T>::value>;
template <typename T>
using is_not_modint_t = enable_if_t<!is_modint<T>::value>;
struct Scanner {
FILE *fp;
char line[(1 << 15) + 1];
size_t st = 0, ed = 0;
void reread() {
memmove(line, line + st, ed - st);
ed -= st;
st = 0;
ed += fread(line + ed, 1, (1 << 15) - ed, fp);
line[ed] = '\0';
}
bool succ() {
while (true) {
if (st == ed) {
reread();
if (st == ed) return false;
}
while (st != ed && isspace(line[st])) st++;
if (st != ed) break;
}
if (ed - st <= 50) {
bool sep = false;
for (size_t i = st; i < ed; i++) {
if (isspace(line[i])) {
sep = true;
break;
}
}
if (!sep) reread();
}
return true;
}
template <class T, enable_if_t<is_same<T, string>::value, int> = 0>
bool read_single(T &ref) {
if (!succ()) return false;
while (true) {
size_t sz = 0;
while (st + sz < ed && !isspace(line[st + sz])) sz++;
ref.append(line + st, sz);
st += sz;
if (!sz || st != ed) break;
reread();
}
return true;
}
template <class T, enable_if_t<is_integral<T>::value, int> = 0>
bool read_single(T &ref) {
if (!succ()) return false;
bool neg = false;
if (line[st] == '-') {
neg = true;
st++;
}
ref = T(0);
while (isdigit(line[st])) { ref = 10 * ref + (line[st++] & 0xf); }
if (neg) ref = -ref;
return true;
}
template <class T, is_modint_t<T> * = nullptr>
bool read_single(T &ref) {
long long val = 0;
bool f = read_single(val);
ref = T(val);
return f;
}
bool read_single(double &ref) {
string s;
if (!read_single(s)) return false;
ref = std::stod(s);
return true;
}
bool read_single(char &ref) {
string s;
if (!read_single(s) || s.size() != 1) return false;
ref = s[0];
return true;
}
template <class T>
bool read_single(vector<T> &ref) {
for (auto &d: ref) {
if (!read_single(d)) return false;
}
return true;
}
template <class T, class U>
bool read_single(pair<T, U> &p) {
return (read_single(p.first) && read_single(p.second));
}
template <class A, class B, class C>
bool read_single(tuple<A, B, C> &p) {
return (read_single(get<0>(p)) && read_single(get<1>(p))
&& read_single(get<2>(p)));
}
template <class A, class B, class C, class D>
bool read_single(tuple<A, B, C, D> &p) {
return (read_single(get<0>(p)) && read_single(get<1>(p))
&& read_single(get<2>(p)) && read_single(get<3>(p)));
}
void read() {}
template <class H, class... T>
void read(H &h, T &... t) {
bool f = read_single(h);
assert(f);
read(t...);
}
Scanner(FILE *fp) : fp(fp) {}
};
struct Printer {
Printer(FILE *_fp) : fp(_fp) {}
~Printer() { flush(); }
static constexpr size_t SIZE = 1 << 15;
FILE *fp;
char line[SIZE], small[50];
size_t pos = 0;
void flush() {
fwrite(line, 1, pos, fp);
pos = 0;
}
void write(const char &val) {
if (pos == SIZE) flush();
line[pos++] = val;
}
template <class T, enable_if_t<is_integral<T>::value, int> = 0>
void write(T val) {
if (pos > (1 << 15) - 50) flush();
if (val == 0) {
write('0');
return;
}
if (val < 0) {
write('-');
val = -val; // todo min
}
size_t len = 0;
while (val) {
small[len++] = char(0x30 | (val % 10));
val /= 10;
}
for (size_t i = 0; i < len; i++) { line[pos + i] = small[len - 1 - i]; }
pos += len;
}
void write(const string &s) {
for (char c: s) write(c);
}
void write(const char *s) {
size_t len = strlen(s);
for (size_t i = 0; i < len; i++) write(s[i]);
}
void write(const double &x) {
ostringstream oss;
oss << setprecision(15) << x;
string s = oss.str();
write(s);
}
void write(const long double &x) {
ostringstream oss;
oss << setprecision(15) << x;
string s = oss.str();
write(s);
}
template <class T, is_modint_t<T> * = nullptr>
void write(T &ref) {
write(ref.val);
}
template <class T>
void write(const vector<T> &val) {
auto n = val.size();
for (size_t i = 0; i < n; i++) {
if (i) write(' ');
write(val[i]);
}
}
template <class T, class U>
void write(const pair<T, U> &val) {
write(val.first);
write(' ');
write(val.second);
}
template <class A, class B, class C>
void write(const tuple<A, B, C> &val) {
auto &[a, b, c] = val;
write(a), write(' '), write(b), write(' '), write(c);
}
template <class A, class B, class C, class D>
void write(const tuple<A, B, C, D> &val) {
auto &[a, b, c, d] = val;
write(a), write(' '), write(b), write(' '), write(c), write(' '), write(d);
}
template <class A, class B, class C, class D, class E>
void write(const tuple<A, B, C, D, E> &val) {
auto &[a, b, c, d, e] = val;
write(a), write(' '), write(b), write(' '), write(c), write(' '), write(d), write(' '), write(e);
}
template <class A, class B, class C, class D, class E, class F>
void write(const tuple<A, B, C, D, E, F> &val) {
auto &[a, b, c, d, e, f] = val;
write(a), write(' '), write(b), write(' '), write(c), write(' '), write(d), write(' '), write(e), write(' '), write(f);
}
template <class T, size_t S>
void write(const array<T, S> &val) {
auto n = val.size();
for (size_t i = 0; i < n; i++) {
if (i) write(' ');
write(val[i]);
}
}
void write(i128 val) {
string s;
bool negative = 0;
if(val < 0){
negative = 1;
val = -val;
}
while (val) {
s += '0' + int(val % 10);
val /= 10;
}
if(negative) s += "-";
reverse(all(s));
if (len(s) == 0) s = "0";
write(s);
}
};
Scanner scanner = Scanner(stdin);
Printer printer = Printer(stdout);
void flush() { printer.flush(); }
void print() { printer.write('\n'); }
template <class Head, class... Tail>
void print(Head &&head, Tail &&... tail) {
printer.write(head);
if (sizeof...(Tail)) printer.write(' ');
print(forward<Tail>(tail)...);
}
void read() {}
template <class Head, class... Tail>
void read(Head &head, Tail &... tail) {
scanner.read(head);
read(tail...);
}
#define INT(...) \
int __VA_ARGS__; \
read(__VA_ARGS__)
#define LL(...) \
ll __VA_ARGS__; \
read(__VA_ARGS__)
#define STR(...) \
string __VA_ARGS__; \
read(__VA_ARGS__)
#define CHAR(...) \
char __VA_ARGS__; \
read(__VA_ARGS__)
#define DBL(...) \
double __VA_ARGS__; \
read(__VA_ARGS__)
#define VEC(type, name, size) \
vector<type> name(size); \
read(name)
#define VV(type, name, h, w) \
vector<vector<type>> name(h, vector<type>(w)); \
read(name)
void YES(bool t = 1) { print(t ? "YES" : "NO"); }
void NO(bool t = 1) { YES(!t); }
void Yes(bool t = 1) { print(t ? "Yes" : "No"); }
void No(bool t = 1) { Yes(!t); }
void yes(bool t = 1) { print(t ? "yes" : "no"); }
void no(bool t = 1) { yes(!t); }
#line 1 "library/ds/cht_monotone.hpp"
template <typename T, bool isMin>
struct CHT_monotone {
#define F first
#define S second
using P = pair<T, T>;
deque<P> H;
CHT_monotone() = default;
bool empty() const { return H.empty(); }
void clear() { H.clear(); }
inline int sgn(T x) { return x == 0 ? 0 : (x < 0 ? -1 : 1); }
using D = long double;
inline bool check(const P &a, const P &b, const P &c) {
if (b.S == a.S || c.S == b.S)
return sgn(b.F - a.F) * sgn(c.S - b.S) >= sgn(c.F - b.F) * sgn(b.S - a.S);
return (b.F - a.F) * (c.S - b.S) >= (b.S - a.S) * (c.F - b.F);
// return D(b.F - a.F) * sgn(c.S - b.S) / D(abs(b.S - a.S)) >=
// D(c.F - b.F) * sgn(b.S - a.S) / D(abs(c.S - b.S));
}
void add(T a, T b) {
if (!isMin) a *= -1, b *= -1;
P line(a, b);
if (empty()) {
H.emplace_front(line);
return;
}
if (H.front().F <= a) {
if (H.front().F == a) {
if (H.front().S <= b) return;
H.pop_front();
}
while (H.size() >= 2 && check(line, H.front(), H[1])) H.pop_front();
H.emplace_front(line);
} else {
assert(a <= H.back().F);
if (H.back().F == a) {
if (H.back().S <= b) return;
H.pop_back();
}
while (H.size() >= 2 && check(H[H.size() - 2], H.back(), line))
H.pop_back();
H.emplace_back(line);
}
}
inline T get_y(const P &a, const T &x) { return a.F * x + a.S; }
T query(T x) {
assert(!empty());
int l = -1, r = H.size() - 1;
while (l + 1 < r) {
int m = (l + r) >> 1;
if (get_y(H[m], x) >= get_y(H[m + 1], x))
l = m;
else
r = m;
}
if (isMin) return get_y(H[r], x);
return -get_y(H[r], x);
}
T query_monotone_inc(T x) {
assert(!empty());
while (H.size() >= 2 && get_y(H.front(), x) >= get_y(H[1], x))
H.pop_front();
if (isMin) return get_y(H.front(), x);
return -get_y(H.front(), x);
}
T query_monotone_dec(T x) {
assert(!empty());
while (H.size() >= 2 && get_y(H.back(), x) >= get_y(H[H.size() - 2], x))
H.pop_back();
if (isMin) return get_y(H.back(), x);
return -get_y(H.back(), x);
}
#undef F
#undef S
};
#line 4 "main.cpp"
void solve() {
LL(N);
vi X = {1}, DX = {0};
FOR(N) {
LL(a, b, c);
X.eb(a);
X.eb(b);
DX.eb(c);
DX.eb(c);
}
auto I = argsort(X);
X = rearrange(X, I);
DX = rearrange(DX, I);
DX = cumsum(DX, 0);
CHT_monotone<i128, 0> cht;
FOR(i, len(X)) { cht.add(-2 * X[i], DX[i]); }
vc<i128> Y;
FOR(i, len(X)) {
i128 y = cht.query_monotone_inc(X[i]) + DX[i];
Y.eb(y - DX.back());
}
print(MAX(Y) * 0.5);
}
signed main() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << setprecision(15);
ll T = 1;
// LL(T);
FOR(T) solve();
return 0;
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 4056kb
input:
2 1 4 15 3 5 10
output:
2.5
result:
ok found '2.5000000', expected '2.5000000', error '0.0000000'
Test #2:
score: 0
Accepted
time: 0ms
memory: 3948kb
input:
1 2 2 8
output:
4
result:
ok found '4.0000000', expected '4.0000000', error '0.0000000'
Test #3:
score: 0
Accepted
time: 0ms
memory: 3876kb
input:
3 94 68 49 51 2 63 26 85 20
output:
-73
result:
ok found '-73.0000000', expected '-73.0000000', error '-0.0000000'
Test #4:
score: 0
Accepted
time: 0ms
memory: 4040kb
input:
2 14 68 12 28 2 46
output:
-16
result:
ok found '-16.0000000', expected '-16.0000000', error '-0.0000000'
Test #5:
score: 0
Accepted
time: 0ms
memory: 3756kb
input:
5 6 6 8 6 1 11 6 1 13 6 1 5 5 1 2
output:
9.5
result:
ok found '9.5000000', expected '9.5000000', error '0.0000000'
Test #6:
score: 0
Accepted
time: 0ms
memory: 4040kb
input:
5 5 4 2 4 1 10 3 1 3 2 1 3 5 1 5
output:
5.5
result:
ok found '5.5000000', expected '5.5000000', error '0.0000000'
Test #7:
score: 0
Accepted
time: 0ms
memory: 3876kb
input:
5 1 5 2 4 2 7 2 2 2 2 5 14 1 4 2
output:
4.5
result:
ok found '4.5000000', expected '4.5000000', error '0.0000000'
Test #8:
score: 0
Accepted
time: 1ms
memory: 3812kb
input:
5 4 1 9 1 5 13 3 6 10 6 5 8 3 5 5
output:
9
result:
ok found '9.0000000', expected '9.0000000', error '0.0000000'
Test #9:
score: 0
Accepted
time: 0ms
memory: 3884kb
input:
5 3 7 9 5 7 12 4 6 13 3 6 6 2 1 2
output:
-6
result:
ok found '-6.0000000', expected '-6.0000000', error '-0.0000000'
Test #10:
score: 0
Accepted
time: 0ms
memory: 3984kb
input:
10 8 10 26 11 2 28 13 4 13 11 1 26 6 15 23 12 8 7 9 8 11 11 10 17 8 11 18 3 10 27
output:
32
result:
ok found '32.0000000', expected '32.0000000', error '0.0000000'
Test #11:
score: 0
Accepted
time: 0ms
memory: 3816kb
input:
10 6 5 10 10 15 21 7 2 30 14 6 12 1 11 6 1 13 19 8 13 29 9 4 14 1 4 29 4 12 17
output:
12
result:
ok found '12.0000000', expected '12.0000000', error '0.0000000'
Test #12:
score: 0
Accepted
time: 0ms
memory: 3820kb
input:
10 5 15 15 3 14 20 11 14 26 15 12 22 5 15 11 12 10 10 1 12 18 7 7 14 3 5 10 12 9 23
output:
-6
result:
ok found '-6.0000000', expected '-6.0000000', error '-0.0000000'
Test #13:
score: 0
Accepted
time: 0ms
memory: 3832kb
input:
10 3 9 29 9 5 27 14 13 21 3 15 15 14 11 24 9 14 22 9 3 20 12 15 27 5 13 21 13 11 14
output:
-5
result:
ok found '-5.0000000', expected '-5.0000000', error '-0.0000000'
Test #14:
score: 0
Accepted
time: 0ms
memory: 3820kb
input:
10 3 13 11 3 5 20 9 10 1 5 5 25 10 1 29 6 10 26 1 15 1 10 10 18 6 6 2 14 6 20
output:
21
result:
ok found '21.0000000', expected '21.0000000', error '0.0000000'
Test #15:
score: 0
Accepted
time: 0ms
memory: 3888kb
input:
100 68 91 90 56 38 71 69 57 87 80 62 21 31 80 25 36 48 40 71 66 49 15 57 78 96 69 43 25 73 57 86 13 5 23 98 18 83 94 9 8 22 43 46 3 50 81 11 26 14 35 39 49 68 73 41 11 25 35 47 48 5 96 15 15 56 60 42 1 40 11 4 25 57 72 9 43 3 90 16 45 36 83 50 17 55 40 39 72 37 6 70 84 24 12 36 95 43 15 13 82 28 68 ...
output:
35.5
result:
ok found '35.5000000', expected '35.5000000', error '0.0000000'
Test #16:
score: 0
Accepted
time: 0ms
memory: 3992kb
input:
100 92 35 39 34 92 36 45 45 46 66 5 64 22 21 48 53 70 91 93 19 98 97 67 54 57 77 64 90 81 23 12 83 92 59 3 26 13 65 47 19 23 58 27 58 38 60 18 70 32 94 53 100 66 97 33 53 16 56 2 64 8 9 55 93 92 22 27 25 39 45 49 24 76 80 89 73 55 77 69 53 90 39 77 40 86 12 11 23 87 25 8 96 31 73 45 98 52 62 55 98 9...
output:
-100
result:
ok found '-100.0000000', expected '-100.0000000', error '-0.0000000'
Test #17:
score: 0
Accepted
time: 0ms
memory: 3864kb
input:
100 20 84 93 15 45 13 28 33 2 49 41 12 12 50 59 62 89 49 11 60 42 74 84 33 14 94 85 51 2 89 26 66 87 92 12 26 47 32 84 34 16 80 20 16 27 48 34 14 54 61 66 52 47 21 41 87 3 81 45 68 24 18 94 71 23 87 12 49 34 79 6 6 91 92 56 3 15 64 22 69 41 91 3 60 21 76 79 65 41 48 46 9 35 34 54 92 68 10 1 22 82 17...
output:
25.5
result:
ok found '25.5000000', expected '25.5000000', error '0.0000000'
Test #18:
score: 0
Accepted
time: 0ms
memory: 4052kb
input:
100 44 28 47 89 7 89 7 21 57 27 92 56 14 96 86 79 11 7 29 4 95 56 93 16 71 2 6 100 14 59 53 32 82 24 20 35 73 7 22 44 9 91 5 70 24 31 41 50 72 19 80 100 44 46 33 26 94 2 4 72 27 35 29 49 54 44 92 73 33 13 55 92 6 3 31 37 76 47 75 77 87 44 33 80 63 48 51 12 90 66 83 17 46 99 59 78 76 61 35 39 52 91 9...
output:
-57
result:
ok found '-57.0000000', expected '-57.0000000', error '-0.0000000'
Test #19:
score: 0
Accepted
time: 0ms
memory: 3960kb
input:
100 68 73 96 63 60 58 86 13 29 13 32 95 4 25 97 96 30 61 55 57 43 34 98 95 32 14 27 65 26 38 79 10 69 56 33 35 98 82 59 55 9 5 82 25 12 19 53 94 90 82 6 48 29 70 29 60 76 23 59 89 38 44 64 31 81 10 77 96 24 51 99 79 25 19 11 68 32 34 28 89 38 100 64 4 94 16 19 58 40 89 17 34 57 64 69 80 92 12 81 63 ...
output:
-81.5
result:
ok found '-81.5000000', expected '-81.5000000', error '-0.0000000'
Test #20:
score: 0
Accepted
time: 65ms
memory: 27776kb
input:
200000 14 11 10 2 6 10 18 13 7 8 5 11 13 5 14 16 14 2 4 5 17 4 20 7 7 3 9 9 8 11 15 1 20 19 13 3 19 17 15 9 16 20 5 5 15 2 1 6 11 14 13 8 13 7 2 3 10 7 18 9 1 4 12 17 3 7 14 4 17 12 14 11 18 11 6 11 7 15 10 4 13 13 2 14 2 1 18 7 3 18 12 16 19 17 13 7 7 17 1 20 9 2 2 1 2 6 13 11 7 11 9 20 16 3 9 4 4 ...
output:
2100856
result:
ok found '2100856.0000000', expected '2100856.0000000', error '0.0000000'
Test #21:
score: 0
Accepted
time: 65ms
memory: 26640kb
input:
200000 18 20 15 4 20 7 1 5 6 6 8 19 3 2 5 14 17 17 2 18 18 17 18 10 8 11 11 6 9 2 1 19 11 16 18 7 13 8 13 7 9 2 6 4 12 6 9 10 5 5 6 16 2 15 18 18 1 8 9 1 8 10 11 14 18 12 19 8 8 18 11 17 9 19 1 17 3 2 3 11 15 9 17 10 12 17 6 14 17 20 10 16 11 18 2 6 16 5 3 4 2 16 3 16 16 16 11 14 4 2 4 5 8 6 17 8 9 ...
output:
2101118
result:
ok found '2101118.0000000', expected '2101118.0000000', error '0.0000000'
Test #22:
score: 0
Accepted
time: 53ms
memory: 27704kb
input:
200000 6 4 9 1 13 15 16 13 6 13 8 19 5 11 12 11 3 11 4 19 6 3 7 9 9 20 12 3 17 12 4 6 6 8 3 8 19 3 6 14 13 13 19 18 20 13 20 10 3 20 4 4 11 15 15 12 12 9 16 9 20 7 6 12 1 17 4 11 7 12 16 4 8 11 17 11 19 5 16 3 14 5 3 18 15 17 17 20 7 19 8 9 18 7 12 16 12 12 17 8 11 10 4 19 11 18 18 17 13 9 12 10 20 ...
output:
2100494
result:
ok found '2100494.0000000', expected '2100494.0000000', error '0.0000000'
Test #23:
score: 0
Accepted
time: 54ms
memory: 27196kb
input:
200000 10 4 6 3 15 8 20 17 1 15 3 10 16 12 3 12 2 13 7 4 19 5 16 12 18 20 9 16 17 2 6 4 17 4 16 16 13 18 8 5 6 7 4 13 17 17 12 10 17 10 6 16 16 4 7 19 19 14 11 13 3 4 5 10 13 15 5 15 6 10 4 18 11 2 4 1 15 7 1 11 4 14 17 2 10 9 5 7 16 2 18 1 5 12 1 10 20 3 19 16 20 4 5 14 17 19 17 16 9 4 11 14 12 15 ...
output:
2104832
result:
ok found '2104832.0000000', expected '2104832.0000000', error '0.0000000'
Test #24:
score: 0
Accepted
time: 62ms
memory: 28520kb
input:
200000 14 9 12 13 9 5 7 10 8 13 7 10 6 2 10 9 4 3 9 12 7 3 6 11 15 12 10 1 10 9 12 19 4 17 4 16 6 5 5 19 7 6 1 3 6 20 3 14 15 5 20 7 10 4 11 13 10 15 2 5 14 13 16 12 8 20 6 15 17 4 17 20 7 18 3 12 15 10 14 19 19 10 8 6 1 1 9 14 6 4 12 2 16 13 10 4 8 15 13 20 1 19 2 1 11 5 8 15 14 16 15 19 8 18 9 19 ...
output:
2103344
result:
ok found '2103344.0000000', expected '2103344.0000000', error '0.0000000'
Test #25:
score: 0
Accepted
time: 62ms
memory: 28296kb
input:
200000 18 17 6 14 18 10 18 18 4 15 7 14 20 3 1 18 19 6 7 17 8 8 19 7 16 20 11 18 10 19 18 13 4 13 17 20 12 20 3 6 20 20 6 18 19 20 15 18 17 12 13 11 15 4 7 11 12 16 13 14 18 10 15 14 19 1 15 2 16 18 6 11 6 2 19 2 15 17 11 15 1 6 14 13 4 5 1 20 11 3 10 6 4 18 19 19 5 18 3 17 15 5 3 8 6 11 6 2 10 11 1...
output:
2099791
result:
ok found '2099791.0000000', expected '2099791.0000000', error '0.0000000'
Test #26:
score: 0
Accepted
time: 61ms
memory: 27992kb
input:
200000 6 17 15 12 20 7 6 18 19 2 18 17 6 16 8 15 1 16 5 2 16 6 8 6 13 9 8 15 2 17 12 3 15 5 18 4 18 11 5 13 12 15 19 12 15 20 6 14 15 10 7 7 12 17 19 6 19 1 8 18 5 15 15 16 2 19 4 6 7 12 11 13 1 13 6 16 19 4 16 19 16 2 20 17 19 13 13 7 5 2 4 3 15 7 16 13 13 9 17 1 4 19 4 15 8 17 13 5 15 2 18 5 12 11...
output:
2097689
result:
ok found '2097689.0000000', expected '2097689.0000000', error '0.0000000'
Test #27:
score: 0
Accepted
time: 66ms
memory: 27964kb
input:
200000 6 10 9 9 13 3 1 6 19 20 18 1 17 9 7 12 20 18 7 15 9 4 17 9 10 9 10 15 3 8 18 2 2 18 7 8 3 6 18 11 13 13 15 11 4 7 14 18 13 17 1 15 13 13 15 20 10 2 15 10 16 16 10 13 17 20 17 6 6 2 8 19 16 9 5 6 20 7 10 7 7 14 11 5 14 9 16 9 15 20 2 15 18 20 5 7 9 8 19 17 1 13 5 10 3 3 12 20 12 18 17 14 17 2 ...
output:
2104030
result:
ok found '2104030.0000000', expected '2104030.0000000', error '0.0000000'
Test #28:
score: 0
Accepted
time: 62ms
memory: 26624kb
input:
200000 14 14 19 19 15 8 4 18 14 2 17 9 11 7 18 9 6 8 9 15 9 1 11 8 11 17 11 16 15 14 16 12 1 10 20 13 17 5 20 18 10 12 20 5 13 11 18 2 7 16 14 3 2 5 7 18 17 3 6 18 20 10 9 11 8 5 6 13 5 16 12 6 11 1 5 17 16 14 3 3 13 7 1 17 13 9 8 20 4 7 19 16 5 5 11 1 17 16 1 17 14 7 6 1 1 9 2 3 16 5 1 7 9 5 13 3 1...
output:
2098865
result:
ok found '2098865.0000000', expected '2098865.0000000', error '0.0000000'
Test #29:
score: 0
Accepted
time: 55ms
memory: 27852kb
input:
200000 14 1 14 8 20 15 2 15 11 20 16 8 3 15 5 20 19 2 1 18 11 8 16 7 4 17 12 14 15 17 8 9 10 5 20 10 2 4 11 15 20 19 20 15 16 14 13 14 5 17 15 17 3 7 8 8 7 3 8 14 19 6 13 4 15 19 10 18 9 7 20 17 5 8 8 7 6 6 18 3 15 2 17 14 3 17 5 11 2 19 12 20 10 10 5 2 7 18 9 13 11 12 20 13 15 12 20 2 15 17 3 13 18...
output:
2102647
result:
ok found '2102647.0000000', expected '2102647.0000000', error '0.0000000'
Test #30:
score: 0
Accepted
time: 66ms
memory: 27160kb
input:
200000 558273441 797132086 95394395 410375788 603346154 991788394 501822655 954838746 104557620 987594944 800261563 456008910 944698458 473660405 947257686 43525951 515134254 221154267 581712330 247867513 268703732 553202136 786196487 556214428 384021989 736444004 231738414 760952860 568578734 24958...
output:
-999998979
result:
ok found '-999998979.0000000', expected '-999998979.0000000', error '-0.0000000'
Test #31:
score: 0
Accepted
time: 79ms
memory: 27528kb
input:
200000 441389569 370680930 99240357 581229458 437471216 536267171 936627342 298022734 325491775 269899126 474522003 217568653 587531252 498486839 464195305 120973868 798381976 80434530 750110349 687131754 560991673 878382618 156079804 73056107 406335846 606754213 944832635 486601913 447068854 291628...
output:
-999998827
result:
ok found '-999998827.0000000', expected '-999998827.0000000', error '-0.0000000'
Test #32:
score: 0
Accepted
time: 69ms
memory: 28428kb
input:
200000 914440289 239197071 838245102 311891640 711787765 931002844 106590814 641206722 546425930 257236013 853815147 274095693 820298639 673056376 831389820 198421785 931886595 84938984 623541071 831428699 413088125 793497691 671187313 440154683 133682407 887129829 657926856 772059478 470783166 1839...
output:
-999998765
result:
ok found '-999998765.0000000', expected '-999998765.0000000', error '-0.0000000'
Test #33:
score: 0
Accepted
time: 77ms
memory: 27160kb
input:
200000 797556417 812745915 432025656 632488413 250945531 770448917 541395501 984390710 177425494 834507491 528075586 740688141 758098729 697882809 53360143 275869702 215134317 239186542 791939089 125468747 560151874 268421277 186294823 956996362 861028968 612215845 665988373 647451634 644240583 3711...
output:
-999996518
result:
ok found '-999996518.0000000', expected '-999996518.0000000', error '-0.0000000'
Test #34:
score: 0
Accepted
time: 75ms
memory: 27256kb
input:
200000 975639841 241070567 25806210 363150595 230294784 314927693 416391676 327574698 398359649 116811673 202336026 797215180 255707331 577485050 420554658 58350323 498382040 243690996 665369811 269765692 707215622 888569055 996369628 178870745 883342825 482526053 379082594 78133391 667954895 263495...
output:
-999999511
result:
ok found '-999999511.0000000', expected '-999999511.0000000', error '-0.0000000'
Test #35:
score: 0
Accepted
time: 79ms
memory: 26720kb
input:
200000 858755969 814619412 469843659 388780073 209644038 299597958 146163660 815982878 619293805 104148560 581629169 413550732 193507421 602311484 642524981 281022432 631886658 397938555 538800533 563805741 704536267 213749537 366252945 695712424 610689386 352836262 92176815 658558252 251477719 1557...
output:
-999997283
result:
ok found '-999997283.0000000', expected '-999997283.0000000', error '-0.0000000'
Test #36:
score: 0
Accepted
time: 82ms
memory: 26568kb
input:
200000 331806689 388168256 63624213 264666446 43769099 844076735 875935643 864199570 400036472 681420038 550856905 470077772 131307512 776881021 304686792 358470349 915134381 552186113 707198551 413135390 556632719 688673122 586393159 917586808 633003243 782954982 805271037 238983113 570159328 48095...
output:
-999999554
result:
ok found '-999999554.0000000', expected '-999999554.0000000', error '-0.0000000'
Test #37:
score: 0
Accepted
time: 65ms
memory: 28016kb
input:
200000 214922817 256684396 802628959 290295924 318085649 388555512 750931818 502350854 620970628 963724220 930150048 936670219 774140306 801707454 231689819 730885562 48638999 851657863 580629273 852399631 703696468 308820900 101500668 284685383 655317100 653265190 518365258 964632166 593873640 2353...
output:
-999997884
result:
ok found '-999997884.0000000', expected '-999997884.0000000', error '-0.0000000'
Test #38:
score: 0
Accepted
time: 73ms
memory: 27132kb
input:
200000 393006241 830233241 396409512 20958105 297434902 373225777 480703802 550567546 841904783 951061106 459186296 993197259 711940396 976276991 748627438 808333480 331886722 710938125 749027291 146439679 995984408 928968678 616608177 801527062 382663661 523575398 231459479 545057027 472363760 1276...
output:
-999996509
result:
ok found '-999996509.0000000', expected '-999996509.0000000', error '-0.0000000'
Test #39:
score: 0
Accepted
time: 72ms
memory: 27848kb
input:
200000 176134865 314986440 192976643 734033578 470296570 221712417 307891930 5847500 328204234 654772568 801336351 645473605 899239098 215972848 448723117 856016589 938455076 584325619 580303234 558661085 890043594 977046894 648887104 547270709 472232271 700221682 176360621 781520985 119330492 54135...
output:
-999994005
result:
ok found '-999994005.0000000', expected '-999994005.0000000', error '-0.0000000'
Test #40:
score: 0
Accepted
time: 72ms
memory: 28052kb
input:
200000 59250993 448343796 786757197 759663055 449645824 471223898 37663913 494255680 549138390 642109454 330372599 702000645 396847700 390542385 110884928 638497210 221702798 883797369 748701252 702958030 182331534 597194672 163994613 769145092 494546128 275564594 889454842 656913142 997820613 94643...
output:
-999996865
result:
ok found '-999996865.0000000', expected '-999996865.0000000', error '-0.0000000'
Test #41:
score: 0
Accepted
time: 71ms
memory: 28248kb
input:
200000 532301713 316859936 525761942 635549429 283770885 310669971 912660088 837439668 475105249 219380932 709665742 463560389 334647790 120401522 37887955 715945127 209983225 743077631 327164678 142222270 34427987 922375153 679102122 285986772 367116881 145874803 897516359 87594899 726567629 133702...
output:
-999989816
result:
ok found '-999989816.0000000', expected '-999989816.0000000', error '-0.0000000'
Test #42:
score: 0
Accepted
time: 72ms
memory: 27924kb
input:
200000 415417842 890408781 119542496 661178906 558087435 372940 642432072 180623656 696039405 501685114 383926182 520087428 567415176 294971059 700049766 793393044 638455139 337516677 495562696 436262319 181491735 397298739 48985440 653085347 389430738 575993523 610610580 668019760 900025045 2600273...
output:
-999999319
result:
ok found '-999999319.0000000', expected '-999999319.0000000', error '-0.0000000'
Test #43:
score: 0
Accepted
time: 69ms
memory: 27772kb
input:
200000 298533970 463957625 418355754 391841088 537436689 839819013 222460951 523807644 916973560 489022001 353153918 281647172 210247971 319797493 627052793 870840961 921702862 196796940 663960714 580559264 473779676 17446517 859060245 169927026 411744595 446303731 28737505 248444620 923739358 91830...
output:
-999999481
result:
ok found '-999999481.0000000', expected '-999999481.0000000', error '-0.0000000'
Test #44:
score: 0
Accepted
time: 79ms
memory: 27648kb
input:
200000 476617394 332473766 157360499 417470566 76594454 384297789 247200230 866991632 842940420 66293479 732447061 897982724 148048061 494367030 289214604 93513070 55207480 496268690 537391437 19823505 620843424 932561591 374167754 391801409 139091156 316613939 36799023 974093673 802229478 665378284...
output:
-999997710
result:
ok found '-999997710.0000000', expected '-999997710.0000000', error '-0.0000000'
Test #45:
score: 0
Accepted
time: 70ms
memory: 27220kb
input:
200000 654700818 611055314 751141053 148132747 55943708 74000758 827229110 210175620 768907279 348597661 406707501 954509763 85848151 519193463 511184927 170960987 338455203 355548952 705789455 18896257 767907173 407485176 594307968 908643088 866437717 186924148 749893244 554518534 825943790 8526454...
output:
-999998470
result:
ok found '-999998470.0000000', expected '-999998470.0000000', error '-0.0000000'
Test #46:
score: 0
Accepted
time: 82ms
memory: 26788kb
input:
200000 832784242 334347262 900211207 318986417 890068769 913446831 557001093 258392312 989841435 335934547 786000644 716069507 728680945 693763000 733155250 953441608 471959821 655020702 284252881 163193202 620003625 732665658 964191285 130517472 888751574 617042868 462987465 280167587 849658103 399...
output:
-999997957
result:
ok found '-999997957.0000000', expected '-999997957.0000000', error '-0.0000000'
Test #47:
score: 0
Accepted
time: 74ms
memory: 26944kb
input:
200000 715900370 907896107 493991760 344615895 164385319 457925608 581740372 896543596 770584102 913206026 460261084 772596547 521256844 718589434 100349765 30889525 755207544 514300965 452650899 307490147 912291566 352813436 479298794 792583343 911065431 192385780 471048982 565625152 23115519 93221...
output:
-999997693
result:
ok found '-999997693.0000000', expected '-999997693.0000000', error '-0.0000000'
Test #48:
score: 0
Accepted
time: 77ms
memory: 26364kb
input:
200000 188951090 481444951 232996506 370245372 143734572 147628577 161769252 239727584 991518258 195510208 134521523 93964802 459056934 598191675 322320088 108337442 888712162 813772715 621048917 601530196 59355315 827737022 994406304 14457726 638411992 62695989 184143203 441017309 751862535 8245123...
output:
-999999902
result:
ok found '-999999902.0000000', expected '-999999902.0000000', error '-0.0000000'
Test #49:
score: 0
Accepted
time: 80ms
memory: 27776kb
input:
200000 971733980 8411329 916539861 153402642 119894963 979199114 574790997 628170531 504333076 476475878 640943162 524080762 806375605 656966653 307951111 531700502 700947328 230789962 961660335 995809167 117099285 540912158 282145820 449798541 487416391 495548188 922587305 808721998 103041947 98129...
output:
-999997130
result:
ok found '-999997130.0000000', expected '-999997130.0000000', error '-0.0000000'
Test #50:
score: 0
Accepted
time: 75ms
memory: 28620kb
input:
200000 149817404 581960174 510320415 473999416 99244217 818645187 449787172 676387223 430299935 463812764 315203602 435383609 744175695 536568894 234954138 609148419 984195051 385037521 835091057 289849216 264163034 161059936 92220625 816897116 509730248 70891100 930648823 239403755 126756259 990429...
output:
-999999684
result:
ok found '-999999684.0000000', expected '-999999684.0000000', error '-0.0000000'
Test #51:
score: 0
Accepted
time: 74ms
memory: 26720kb
input:
200000 327900828 450476314 249325161 204661597 933369278 508348156 884591859 19571211 651234091 41084242 989464041 196943353 976943081 856362623 897115949 686596336 117699669 684509271 708521779 434146160 411226782 341016226 607328134 333738795 237076809 941201308 643743044 819828616 710279083 17769...
output:
-999998211
result:
ok found '-999998211.0000000', expected '-999998211.0000000', error '-0.0000000'
Test #52:
score: 0
Accepted
time: 70ms
memory: 26636kb
input:
200000 211016956 878800967 548138418 230291075 912718532 347794228 54555330 362755199 872168246 323388425 368757185 253470393 619775875 735964865 824118976 764044253 105980096 838756829 581952501 728186209 558290531 256131299 122435644 555613179 964423370 811511517 651804561 400253477 28960692 69996...
output:
-999997901
result:
ok found '-999997901.0000000', expected '-999997901.0000000', error '-0.0000000'
Test #53:
score: 0
Accepted
time: 74ms
memory: 27432kb
input:
200000 94133084 452349811 287143164 255920552 187035081 892273005 489360018 705939188 798135106 310725311 43017625 15030136 412351774 55758594 486280787 546524875 534452010 843261283 750350520 577515858 555611175 876279077 197351665 72454858 986737227 241630237 364898782 125902530 52675004 817072436...
output:
-999995604
result:
ok found '-999995604.0000000', expected '-999995604.0000000', error '-0.0000000'
Test #54:
score: 0
Accepted
time: 73ms
memory: 27848kb
input:
200000 567183804 25898655 880923718 131806926 21160143 436751782 364356193 49123176 19069261 887996789 572053872 776589880 350151864 230328131 3218406 769196984 817699732 997508842 918748538 16780099 702674924 351202663 712459174 439553433 9051084 111940445 77993003 706327391 226132420 709372307 287...
output:
-999995094
result:
ok found '-999995094.0000000', expected '-999995094.0000000', error '-0.0000000'
Test #55:
score: 0
Accepted
time: 77ms
memory: 28088kb
input:
200000 450299932 599447500 324961167 157436404 509396 421422047 94128176 392307164 945036121 170300971 246314312 392925432 992984658 960187268 75445625 846644901 100947455 2013296 792179260 310820147 849738673 676383145 522533980 956395112 736397645 982250654 231278712 137009148 954879437 896639473 ...
output:
-999997310
result:
ok found '-999997310.0000000', expected '-999997310.0000000', error '-0.0000000'
Test #56:
score: 0
Accepted
time: 72ms
memory: 27064kb
input:
200000 628383356 467963640 623774425 888098585 979858650 670933528 823900160 735491152 871002980 157637858 920574751 449452471 930784748 134756806 592383244 924092818 234452073 156260854 665609982 455117092 142026613 296530922 37641489 883302199 758711502 707336670 944372933 12401305 128336853 78893...
output:
-999995345
result:
ok found '-999995345.0000000', expected '-999995345.0000000', error '-0.0000000'
Test #57:
score: 0
Accepted
time: 73ms
memory: 28000kb
input:
200000 511499485 41512484 217554979 913728063 813983712 215412304 403929039 78675140 91937135 734909336 299867895 211012215 868584839 159583239 519386271 1540735 222732500 160765308 539040704 894381333 994123066 916678700 407524806 105176583 781025359 987712286 657467155 592826166 152051166 68123921...
output:
-999998477
result:
ok found '-999998477.0000000', expected '-999998477.0000000', error '-0.0000000'
Test #58:
score: 0
Accepted
time: 68ms
memory: 26920kb
input:
200000 984550205 174869841 956559724 789614437 88300261 200082569 428668318 421859128 167647099 17213518 974128335 267539255 511417633 334152776 181548082 78988652 651204414 315012866 707438722 893454086 141186814 391602286 922632316 622018262 508371920 858022494 665528672 23507923 30541286 57353908...
output:
-999996461
result:
ok found '-999996461.0000000', expected '-999996461.0000000', error '-0.0000000'
Test #59:
score: 0
Accepted
time: 66ms
memory: 27192kb
input:
200000 622108903 996803515 640103080 17482106 64460652 326620403 691946959 810302075 385494621 152954996 775517269 552431022 8479408 392927754 726987616 797319008 168472284 732030114 193274332 582700353 493898081 104777423 210371832 202583269 357376318 141131590 403972774 391212612 231977593 8471565...
output:
-999999076
result:
ok found '-999999076.0000000', expected '-999999076.0000000', error '-0.0000000'
Test #60:
score: 0
Accepted
time: 31ms
memory: 26820kb
input:
200000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000000000 1 1 1000...
output:
199999999999999
result:
ok found '199999999999999.0000000', expected '199999999999999.0000000', error '0.0000000'
Test #61:
score: 0
Accepted
time: 28ms
memory: 27884kb
input:
200000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000...
output:
-1000000000
result:
ok found '-1000000000.0000000', expected '-1000000000.0000000', error '-0.0000000'
Test #62:
score: 0
Accepted
time: 34ms
memory: 26944kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
198999998985951
result:
ok found '198999998985951.0000000', expected '198999998985951.0000000', error '0.0000000'
Test #63:
score: 0
Accepted
time: 30ms
memory: 28260kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
197999995971951
result:
ok found '197999995971951.0000000', expected '197999995971951.0000000', error '0.0000000'
Test #64:
score: 0
Accepted
time: 36ms
memory: 27040kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
189999899859951
result:
ok found '189999899859951.0000000', expected '189999899859951.0000000', error '0.0000000'
Test #65:
score: 0
Accepted
time: 31ms
memory: 28408kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
179999599719951
result:
ok found '179999599719951.0000000', expected '179999599719951.0000000', error '0.0000000'
Test #66:
score: 0
Accepted
time: 28ms
memory: 27452kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
159998399439951
result:
ok found '159998399439951.0000000', expected '159998399439951.0000000', error '0.0000000'
Test #67:
score: 0
Accepted
time: 30ms
memory: 26896kb
input:
200000 1 2 1 3 4 1 5 6 1 7 8 1 9 10 1 11 12 1 13 14 1 15 16 1 17 18 1 19 20 1 21 22 1 23 24 1 25 26 1 27 28 1 29 30 1 31 32 1 33 34 1 35 36 1 37 38 1 39 40 1 41 42 1 43 44 1 45 46 1 47 48 1 49 50 1 51 52 1 53 54 1 55 56 1 57 58 1 59 60 1 61 62 1 63 64 1 65 66 1 67 68 1 69 70 1 71 72 1 73 74 1 75 76 ...
output:
119993598879951
result:
ok found '119993598879951.0000000', expected '119993598879951.0000000', error '0.0000000'
Test #68:
score: 0
Accepted
time: 1ms
memory: 3924kb
input:
20 1 1 20 2 2 19 3 3 18 4 4 17 5 5 16 6 6 15 7 7 14 8 8 13 9 9 12 10 10 11 11 11 10 12 12 9 13 13 8 14 14 7 15 15 6 16 16 5 17 17 4 18 18 3 19 19 2 20 20 1
output:
0
result:
ok found '0.0000000', expected '0.0000000', error '-0.0000000'
Test #69:
score: 0
Accepted
time: 1ms
memory: 3948kb
input:
200 1 1 200 2 2 199 3 3 198 4 4 197 5 5 196 6 6 195 7 7 194 8 8 193 9 9 192 10 10 191 11 11 190 12 12 189 13 13 188 14 14 187 15 15 186 16 16 185 17 17 184 18 18 183 19 19 182 20 20 181 21 21 180 22 22 179 23 23 178 24 24 177 25 25 176 26 26 175 27 27 174 28 28 173 29 29 172 30 30 171 31 31 170 32 3...
output:
0
result:
ok found '0.0000000', expected '0.0000000', error '-0.0000000'
Test #70:
score: 0
Accepted
time: 1ms
memory: 4116kb
input:
2000 1 1 2000 2 2 1999 3 3 1998 4 4 1997 5 5 1996 6 6 1995 7 7 1994 8 8 1993 9 9 1992 10 10 1991 11 11 1990 12 12 1989 13 13 1988 14 14 1987 15 15 1986 16 16 1985 17 17 1984 18 18 1983 19 19 1982 20 20 1981 21 21 1980 22 22 1979 23 23 1978 24 24 1977 25 25 1976 26 26 1975 27 27 1974 28 28 1973 29 29...
output:
0
result:
ok found '0.0000000', expected '0.0000000', error '-0.0000000'
Test #71:
score: 0
Accepted
time: 33ms
memory: 30936kb
input:
200000 1 1 200000 2 2 199999 3 3 199998 4 4 199997 5 5 199996 6 6 199995 7 7 199994 8 8 199993 9 9 199992 10 10 199991 11 11 199990 12 12 199989 13 13 199988 14 14 199987 15 15 199986 16 16 199985 17 17 199984 18 18 199983 19 19 199982 20 20 199981 21 21 199980 22 22 199979 23 23 199978 24 24 199977...
output:
0
result:
ok found '0.0000000', expected '0.0000000', error '-0.0000000'