제출 #406395

#제출 시각UTC-0아이디문제언어결과실행 시간메모리
4063952021-05-17 14:19:12atoizNicelines (RMI20_nicelines)C++14
11 / 100
2 ms292 KiB
#include <stdio.h>
#include <math.h>
#include <algorithm>
#include <vector>
#include "nice_lines.h"
const int X = 100000;
bool zero(long double x) { return std::abs(x) < 100; }
bool equals(long double x, long double y) { return zero(x - y); }
void add(int64_t Y, std::vector<int> &A, std::vector<int> &B) {
int b = int(Y % X);
while (b > 10000) b -= X;
while (b < -10000) b += X;
A.push_back((Y - b) / X), B.push_back(b);
}
int64_t roundDouble(long double x) {
if (x < 0) return -int64_t(0.5 - x);
else return int64_t(x + 0.5);
}
void solve_range(int64_t lo, long double dist_lo_0, long double dist_lo_1, int64_t hi, long double dist_hi_0, long double dist_hi_1, std::vector<int> &a, std::vector<int> &b) {
long double diff_lo = (dist_lo_1 - dist_lo_0), diff_hi = (dist_hi_1 - dist_hi_0);
// if (lo >= hi) return;
// if (equals(dist_lo_0 + diff_lo * ((hi - lo) / 10000) * 0.25, dist_hi_0)) return;
// if (equals(dist_hi_0 + diff_hi * ((lo - hi) / 10000) * 0.25, dist_lo_0)) return;
 
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...