제출 #1128657

#제출 시각아이디문제언어결과실행 시간메모리
1128657Zero_OPChessboard (IZhO18_chessboard)C++20
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; #define rep(i, l, r) for(int i = (l); i < (r); ++i) #define sz(v) (int)v.size() #define dbg(x) "[" #x " = " << (x) << "]" #define all(v) begin(v), end(v) #define compact(v) v.erase(unique(all(v)), end(v)) #define file(name) if(fopen(name".inp", "r")){ freopen(name".inp", "r", stdin); freopen(name".out", "w", stdout); } template<typename T> bool minimize(T& a, const T& b){ if(a > b){ return a = b, true; } return false; } template<typename T> bool maximize(T& a, const T& b){ if(a < b){ return a = b, true; } return false; } mt19937 rng(chrono::steady_clock::now().time_since_epoch().count()); using ll = long long; using ld = long double; using ull = unsigned long long; using vi = vector<int>; using vl = vector<ll>; const int MAX = 1e5 + 5; #define x1 __x1 #define y1 __y1 #define x2 __x2 #define y2 __y2 int N, K, x1[MAX], y1[MAX], x2[MAX], y2[MAX]; //blocks size d are numbered from 0 to (N / d) - 1 //the cells are also numbered from (0, 0) to (N - 1, N - 1) //block of the cell : // block of x : x / d // block of y : y / d ll area(int x1, int y1, int x2, int y2){ return 1LL * (x2 - x1 + 1) * (y2 - y1 + 1); } //ll solve_in_block(int bx, int by, int x1, int y1, int x2, int y2){ // //} // //ll solve_half_head_in_block(int bx, int by, int x1, int y1, int x2, int y2){ // //} bool check(int x, int y, int z){ return ((x + y) & 1) == z; } #define on_debug true void output(string s){ if(on_debug) cout << s << '\n'; } int A[2], a[2], b[2]; ll solve(int d, bool add){ //(block of x) + (block of y) % 2 = add => black block A[0] = A[1] = (N / d) / 2; if((N / d) & 1) ++A[0]; ll result = 0; for(int i = 0; i < 2; ++i){ for(int j = 0; j < 2; ++j){ if(check(i, j, !add)) result += 1LL * A[i] * A[j] * d * d; } } // ll backup = 0; for(int i = 0; i < K; ++i){ int lb = (x1[i] / d), rb = (x2[i] / d); int rl = (x1[i] % d), rr = (x2[i] % d); int sb = (y1[i] / d), tb = (y2[i] / d); int rs = (y1[i] % d), rt = (y2[i] % d); // cout << result - backup << '\n'; // backup = result; if(lb == rb){ if(sb == tb){ // output("case 1.1\n"); if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], y2[i]); //wrong color else result -= area(x1[i], y1[i], x2[i], y2[i]); //correct color } else{ // output("case 1.2\n"); //half left part if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], (sb + 1) * d - 1); else result -= area(x1[i], y1[i], x2[i], sb * d - 1); //half right part if(check(lb, tb, add)) result += area(x1[i], tb * d, x2[i], y2[i]); else result -= area(x1[i], tb * d, x2[i], y2[i]); //between blocks int between = (tb - sb - 1); if(between > 0){ int between_odd = (between / 2); int between_even = (between / 2); if(between & 1){ if((sb + 1) & 1) ++between_odd; else ++between_even; } //(lb + parity) if(check(lb, 1, add)){ result += area(x1[i], 1, y2[i], d) * between_odd; result -= area(x1[i], 1, y2[i], d) * between_even; } else{ result -= area(x1[i], 1, y2[i], d) * between_odd; result += area(x1[i], 1, y2[i], d) * between_even; } } } } else{ if(sb == tb){ // output("case 2.1\n"); //half left if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]); else result -= area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]); //half right if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], y2[i]); else result -= area(rb * d, y1[i], x2[i], y2[i]); //between blocks int between = (rb - lb - 1); if(between > 0){ int between_odd = (between / 2); int between_even = (between / 2); if(between & 1){ if((lb + 1) & 1) ++between_odd; else ++between_even; } if(check(sb, 1, add)){ result += area(1, y1[i], d, y2[i]) * between_odd; result -= area(1, y1[i], d, y2[i]) * between_even; } else{ result -= area(1, y1[i], d, y2[i]) * between_odd; result += area(1, y1[i], d, y2[i]) * between_even; } } } else{ // output("case 2.2\n"); ///4 corners blocks //upper-left if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1); else result -= area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1); //upper-right if(check(lb, tb, add)) result += area(x1[i], tb * d, (lb + 1) * d - 1, y2[i]); else result -= area(x1[i], tb * d, (lb + 1) * d - 1, y2[i]); //lower-left if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], (sb + 1) * d - 1); else result -= area(rb * d, y1[i], x2[i], (sb + 1) * d - 1); //lower-right if(check(rb, tb, add)) result += area(rb * d, tb * d, x2[i], y2[i]); else result -= area(rb * d, tb * d, x2[i], y2[i]); ///4 Sides if(rb - lb - 1 > 0){ int between = rb - lb - 1; int between_odd = (between / 2); int between_even = (between) / 2; if(between & 1){ if((lb + 1) & 1) ++between_odd; else ++between_even; } //left side if(check(sb, 1, add)){ result += area(1, y1[i], d, (sb + 1) * d - 1) * between_odd; result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_even; } else{ result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_odd; result += area(1, y1[i], d, (sb + 1) * d - 1) * between_even; } //right side if(check(tb, 1, add)){ result += area(1, tb * d, d, y2[i]) * between_odd; result -= area(1, tb * d, d, y2[i]) * between_even; } else{ result -= area(1, tb * d, d, y2[i]) * between_odd; result += area(1, tb * d, d, y2[i]) * between_even; } } if(tb - sb - 1 > 0){ int between = (tb - sb - 1); int between_odd = (between / 2); int between_even = (between / 2); if(between & 1){ if((sb + 1) & 1) ++between_odd; else ++between_even; } //upper side if(check(lb, 1, add)){ result += area(x1[i], 1, (lb + 1) * d - 1, d) * between_odd; result -= area(x1[i], 1, (lb + 1) * d - 1, d) * between_even; } else{ result -= area(x1[i], 1, (lb + 1) * d - 1, d) * between_odd; result += area(x1[i], 1, (lb + 1) * d - 1, d) * between_even; } //lower side if(check(rb, 1, add)){ result += area(rb * d, 1, x2[i], d) * between_odd; result -= area(rb * d, 1, x2[i], d) * between_even; } else{ result -= area(rb * d, 1, x2[i], d) * between_odd; result += area(rb * d, 1, x2[i], d) * between_even; } } //between - between if(rb - lb - 1 > 0 && tb - sb - 1 > 0){ a[0] = a[1] = (rb - lb - 1) / 2; b[0] = b[1] = (tb - sb - 1) / 2; if((rb - lb - 1) & 1){ if((lb + 1) & 1) ++a[1]; else ++a[0]; } if((tb - sb - 1) & 1){ if((sb + 1) & 1) ++b[1]; else ++b[0]; } for(int i = 0; i < 2; ++i){ for(int j = 0; j < 2; ++j){ if(check(i, j, add)){ result += area(1, 1, d, d) * a[i] * b[j]; } else{ result -= area(1, 1, d, d) * a[i] * b[j]; } } } } } } } return result; } ll solve(int d){ return min(solve(d, 0), solve(d, 1)); } int main(){ ios_base::sync_with_stdio(0); cin.tie(0); file("B"); cin >> N >> K; for(int i = 0; i < K; ++i){ cin >> x1[i] >> y1[i] >> x2[i] >> y2[i]; --x1[i], --y1[i], --x2[i], --y2[i]; } // cout << solve(2, 1) << '\n'; // return 0; ll ans = INT_MAX; for(int i = 1; i * i <= N; ++i){ if(N % i == 0){ ans = min(ans, solve(i)); if(N / i != i && i > 1) ans = min(ans, solve(N / i)); } } cout << ans << '\n'; return 0; }

컴파일 시 표준 에러 (stderr) 메시지

chessboard.cpp:43:26: error: 'int __y1 [100005]' redeclared as different kind of entity
   43 | int N, K, x1[MAX], y1[MAX], x2[MAX], y2[MAX];
      |                          ^
In file included from /usr/include/features.h:486,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/os_defines.h:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/c++config.h:586,
                 from /usr/include/c++/11/cassert:43,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:33,
                 from chessboard.cpp:1:
/usr/include/x86_64-linux-gnu/bits/mathcalls.h:224:1: note: previous declaration 'double __y1(double)'
  224 | __MATHCALL (y1,, (_Mdouble_));
      | ^~~~~~~~~~
chessboard.cpp: In function 'll solve(int, bool)':
chessboard.cpp:94:23: warning: pointer to a function used in arithmetic [-Wpointer-arith]
   94 |         int sb = (y1[i] / d), tb = (y2[i] / d);
      |                       ^
chessboard.cpp:94:25: error: invalid operands of types 'double(double) noexcept' and 'int' to binary 'operator/'
   94 |         int sb = (y1[i] / d), tb = (y2[i] / d);
      |                         ^ ~
      |                           |
      |                           int
chessboard.cpp:95:23: warning: pointer to a function used in arithmetic [-Wpointer-arith]
   95 |         int rs = (y1[i] % d), rt = (y2[i] % d);
      |                       ^
chessboard.cpp:95:25: error: invalid operands of types 'double(double) noexcept' and 'int' to binary 'operator%'
   95 |         int rs = (y1[i] % d), rt = (y2[i] % d);
      |                         ^ ~
      |                           |
      |                           int
chessboard.cpp:101:22: error: 'tb' was not declared in this scope; did you mean 'sb'?
  101 |             if(sb == tb){
      |                      ^~
      |                      sb
chessboard.cpp:103:66: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  103 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], y2[i]); //wrong color
      |                                                                  ^
chessboard.cpp:103:66: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  103 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], y2[i]); //wrong color
      |                                                                  ^
      |                                                                  |
      |                                                                  double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:104:48: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  104 |                 else result -= area(x1[i], y1[i], x2[i], y2[i]); //correct color
      |                                                ^
chessboard.cpp:104:48: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  104 |                 else result -= area(x1[i], y1[i], x2[i], y2[i]); //correct color
      |                                                ^
      |                                                |
      |                                                double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:108:66: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  108 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], (sb + 1) * d - 1);
      |                                                                  ^
chessboard.cpp:108:66: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  108 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], x2[i], (sb + 1) * d - 1);
      |                                                                  ^
      |                                                                  |
      |                                                                  double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:109:48: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  109 |                 else result -= area(x1[i], y1[i], x2[i], sb * d - 1);
      |                                                ^
chessboard.cpp:109:48: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  109 |                 else result -= area(x1[i], y1[i], x2[i], sb * d - 1);
      |                                                ^
      |                                                |
      |                                                double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:136:22: error: 'tb' was not declared in this scope; did you mean 'sb'?
  136 |             if(sb == tb){
      |                      ^~
      |                      sb
chessboard.cpp:139:66: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  139 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]);
      |                                                                  ^
chessboard.cpp:139:66: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  139 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]);
      |                                                                  ^
      |                                                                  |
      |                                                                  double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:140:48: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  140 |                 else result -= area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]);
      |                                                ^
chessboard.cpp:140:48: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  140 |                 else result -= area(x1[i], y1[i], (lb + 1) * d - 1, y2[i]);
      |                                                ^
      |                                                |
      |                                                double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:143:67: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  143 |                 if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], y2[i]);
      |                                                                   ^
chessboard.cpp:143:67: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  143 |                 if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], y2[i]);
      |                                                                   ^
      |                                                                   |
      |                                                                   double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:144:49: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  144 |                 else result -= area(rb * d, y1[i], x2[i], y2[i]);
      |                                                 ^
chessboard.cpp:144:49: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  144 |                 else result -= area(rb * d, y1[i], x2[i], y2[i]);
      |                                                 ^
      |                                                 |
      |                                                 double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:157:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  157 |                         result += area(1, y1[i], d, y2[i]) * between_odd;
      |                                               ^
chessboard.cpp:157:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  157 |                         result += area(1, y1[i], d, y2[i]) * between_odd;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:158:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  158 |                         result -= area(1, y1[i], d, y2[i]) * between_even;
      |                                               ^
chessboard.cpp:158:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  158 |                         result -= area(1, y1[i], d, y2[i]) * between_even;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:160:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  160 |                         result -= area(1, y1[i], d, y2[i]) * between_odd;
      |                                               ^
chessboard.cpp:160:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  160 |                         result -= area(1, y1[i], d, y2[i]) * between_odd;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:161:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  161 |                         result += area(1, y1[i], d, y2[i]) * between_even;
      |                                               ^
chessboard.cpp:161:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  161 |                         result += area(1, y1[i], d, y2[i]) * between_even;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:168:66: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  168 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1);
      |                                                                  ^
chessboard.cpp:168:66: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  168 |                 if(check(lb, sb, add)) result += area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1);
      |                                                                  ^
      |                                                                  |
      |                                                                  double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:169:48: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  169 |                 else result -= area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1);
      |                                                ^
chessboard.cpp:169:48: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  169 |                 else result -= area(x1[i], y1[i], (lb + 1) * d - 1, (sb + 1) * d - 1);
      |                                                ^
      |                                                |
      |                                                double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:176:67: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  176 |                 if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], (sb + 1) * d - 1);
      |                                                                   ^
chessboard.cpp:176:67: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  176 |                 if(check(rb, sb, add)) result += area(rb * d, y1[i], x2[i], (sb + 1) * d - 1);
      |                                                                   ^
      |                                                                   |
      |                                                                   double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:177:49: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  177 |                 else result -= area(rb * d, y1[i], x2[i], (sb + 1) * d - 1);
      |                                                 ^
chessboard.cpp:177:49: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  177 |                 else result -= area(rb * d, y1[i], x2[i], (sb + 1) * d - 1);
      |                                                 ^
      |                                                 |
      |                                                 double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:195:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  195 |                         result += area(1, y1[i], d, (sb + 1) * d - 1) * between_odd;
      |                                               ^
chessboard.cpp:195:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  195 |                         result += area(1, y1[i], d, (sb + 1) * d - 1) * between_odd;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:196:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  196 |                         result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_even;
      |                                               ^
chessboard.cpp:196:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  196 |                         result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_even;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:198:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  198 |                         result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_odd;
      |                                               ^
chessboard.cpp:198:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  198 |                         result -= area(1, y1[i], d, (sb + 1) * d - 1) * between_odd;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp:199:47: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  199 |                         result += area(1, y1[i], d, (sb + 1) * d - 1) * between_even;
      |                                               ^
chessboard.cpp:199:47: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  199 |                         result += area(1, y1[i], d, (sb + 1) * d - 1) * between_even;
      |                                               ^
      |                                               |
      |                                               double (*)(double) noexcept
chessboard.cpp:39:12: note:   initializing argument 2 of 'll area(int, int, int, int)'
   39 | #define y1 __y1
      |            ^
chessboard.cpp:52:21: note: in expansion of macro 'y1'
   52 | ll area(int x1, int y1, int x2, int y2){
      |                     ^~
chessboard.cpp: In function 'int main()':
chessboard.cpp:282:29: warning: pointer to a function used in arithmetic [-Wpointer-arith]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
chessboard.cpp:282:22: error: no match for 'operator>>' (operand types are 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'} and 'double(double) noexcept')
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |         ~~~~~~~~~~~~ ^~
      |             |
      |             std::basic_istream<char>::__istream_type {aka std::basic_istream<char>}
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:120:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__istream_type& (*)(std::basic_istream<_CharT, _Traits>::__istream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  120 |       operator>>(__istream_type& (*__pf)(__istream_type&))
      |       ^~~~~~~~
/usr/include/c++/11/istream:120:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'std::basic_istream<char>::__istream_type& (*)(std::basic_istream<char>::__istream_type&)' {aka 'std::basic_istream<char>& (*)(std::basic_istream<char>&)'} [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:124:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__ios_type& (*)(std::basic_istream<_CharT, _Traits>::__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>; std::basic_istream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]' (near match)
  124 |       operator>>(__ios_type& (*__pf)(__ios_type&))
      |       ^~~~~~~~
/usr/include/c++/11/istream:124:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'std::basic_istream<char>::__ios_type& (*)(std::basic_istream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'} [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:131:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  131 |       operator>>(ios_base& (*__pf)(ios_base&))
      |       ^~~~~~~~
/usr/include/c++/11/istream:131:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'std::ios_base& (*)(std::ios_base&)' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:168:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(bool&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  168 |       operator>>(bool& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:168:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: cannot bind non-const lvalue reference of type 'bool&' to a value of type 'double (*)(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:172:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(short int&) [with _CharT = char; _Traits = std::char_traits<char>]' (near match)
  172 |       operator>>(short& __n);
      |       ^~~~~~~~
/usr/include/c++/11/istream:172:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'short int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(short int)(__y1 + ((sizetype)i))' to 'short int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:175:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(short unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  175 |       operator>>(unsigned short& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:175:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'short unsigned int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(short unsigned int)(__y1 + ((sizetype)i))' to 'short unsigned int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:179:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(int&) [with _CharT = char; _Traits = std::char_traits<char>]' (near match)
  179 |       operator>>(int& __n);
      |       ^~~~~~~~
/usr/include/c++/11/istream:179:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(int)(__y1 + ((sizetype)i))' to 'int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:182:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  182 |       operator>>(unsigned int& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:182:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'unsigned int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(unsigned int)(__y1 + ((sizetype)i))' to 'unsigned int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:186:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  186 |       operator>>(long& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:186:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'long int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(long int)(__y1 + ((sizetype)i))' to 'long int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:190:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  190 |       operator>>(unsigned long& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:190:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'long unsigned int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(long unsigned int)(__y1 + ((sizetype)i))' to 'long unsigned int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:195:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long long int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  195 |       operator>>(long long& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:195:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'long long int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(long long int)(__y1 + ((sizetype)i))' to 'long long int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:199:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long long unsigned int&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  199 |       operator>>(unsigned long long& __n)
      |       ^~~~~~~~
/usr/include/c++/11/istream:199:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'long long unsigned int' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(long long unsigned int)(__y1 + ((sizetype)i))' to 'long long unsigned int&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:235:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(void*&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]' (near match)
  235 |       operator>>(void*& __p)
      |       ^~~~~~~~
/usr/include/c++/11/istream:235:7: note:   conversion of argument 1 would be ill-formed:
chessboard.cpp:282:29: error: invalid conversion from 'double (*)(double) noexcept' to 'void*' [-fpermissive]
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
      |                             |
      |                             double (*)(double) noexcept
chessboard.cpp:282:29: error: cannot bind rvalue '(void*)(__y1 + ((sizetype)i))' to 'void*&'
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:214:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(float&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]'
  214 |       operator>>(float& __f)
      |       ^~~~~~~~
/usr/include/c++/11/istream:214:25: note:   no known conversion for argument 1 from 'double(double) noexcept' to 'float&'
  214 |       operator>>(float& __f)
      |                  ~~~~~~~^~~
/usr/include/c++/11/istream:218:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(double&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]'
  218 |       operator>>(double& __f)
      |       ^~~~~~~~
/usr/include/c++/11/istream:218:26: note:   no known conversion for argument 1 from 'double(double) noexcept' to 'double&'
  218 |       operator>>(double& __f)
      |                  ~~~~~~~~^~~
/usr/include/c++/11/istream:222:7: note: candidate: 'std::basic_istream<_CharT, _Traits>::__istream_type& std::basic_istream<_CharT, _Traits>::operator>>(long double&) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__istream_type = std::basic_istream<char>]'
  222 |       operator>>(long double& __f)
      |       ^~~~~~~~
/usr/include/c++/11/istream:222:31: note:   no known conversion for argument 1 from 'double(double) noexcept' to 'long double&'
  222 |       operator>>(long double& __f)
      |                  ~~~~~~~~~~~~~^~~
/usr/include/c++/11/istream:259:7: note: candidate: 'std::basic_istream<_CharT, _Traits>& std::basic_istream<_CharT, _Traits>::operator>>(std::basic_istream<_CharT, _Traits>::__streambuf_type*) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_istream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<char>]'
  259 |       operator>>(__streambuf_type* __sb);
      |       ^~~~~~~~
/usr/include/c++/11/istream:259:36: note:   no known conversion for argument 1 from 'double(double) noexcept' to 'std::basic_istream<char>::__streambuf_type*' {aka 'std::basic_streambuf<char>*'}
  259 |       operator>>(__streambuf_type* __sb);
      |                  ~~~~~~~~~~~~~~~~~~^~~~
In file included from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:45,
                 from chessboard.cpp:1:
/usr/include/c++/11/cstddef:132:5: note: candidate: 'template<class _IntegerType> constexpr std::__byte_op_t<_IntegerType> std::operator>>(std::byte, _IntegerType)'
  132 |     operator>>(byte __b, _IntegerType __shift) noexcept
      |     ^~~~~~~~
/usr/include/c++/11/cstddef:132:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:13: note:   cannot convert 'std::cin.std::basic_istream<char>::operator>>(__x1[i])' (type 'std::basic_istream<char>::__istream_type' {aka 'std::basic_istream<char>'}) to type 'std::byte'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |         ~~~~^~~~~~~~
In file included from /usr/include/c++/11/string:56,
                 from /usr/include/c++/11/bits/locale_classes.h:40,
                 from /usr/include/c++/11/bits/ios_base.h:41,
                 from /usr/include/c++/11/ios:42,
                 from /usr/include/c++/11/istream:38,
                 from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/bits/basic_string.tcc:1485:5: note: candidate: 'template<class _CharT, class _Traits, class _Alloc> std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&, std::__cxx11::basic_string<_CharT, _Traits, _Allocator>&)'
 1485 |     operator>>(basic_istream<_CharT, _Traits>& __in,
      |     ^~~~~~~~
/usr/include/c++/11/bits/basic_string.tcc:1485:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   mismatched types 'std::__cxx11::basic_string<_CharT, _Traits, _Allocator>' and 'double(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/istream:1016,
                 from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/bits/istream.tcc:958:5: note: candidate: 'template<class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&, _CharT&)'
  958 |     operator>>(basic_istream<_CharT, _Traits>& __in, _CharT& __c)
      |     ^~~~~~~~
/usr/include/c++/11/bits/istream.tcc:958:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   deduced conflicting types for parameter '_CharT' ('char' and 'double(double) noexcept')
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:756:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, unsigned char&)'
  756 |     operator>>(basic_istream<char, _Traits>& __in, unsigned char& __c)
      |     ^~~~~~~~
/usr/include/c++/11/istream:756:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   cannot convert '*(__y1 + ((sizetype)i))' (type 'double(double) noexcept') to type 'unsigned char&'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:761:5: note: candidate: 'template<class _Traits> std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, signed char&)'
  761 |     operator>>(basic_istream<char, _Traits>& __in, signed char& __c)
      |     ^~~~~~~~
/usr/include/c++/11/istream:761:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   cannot convert '*(__y1 + ((sizetype)i))' (type 'double(double) noexcept') to type 'signed char&'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:859:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Num> std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&, _CharT (&)[_Num])'
  859 |     operator>>(basic_istream<_CharT, _Traits>& __in, _CharT (&__s)[_Num])
      |     ^~~~~~~~
/usr/include/c++/11/istream:859:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   mismatched types '_CharT [_Num]' and 'double(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:868:5: note: candidate: 'template<class _Traits, long unsigned int _Num> std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, unsigned char (&)[_Num])'
  868 |     operator>>(basic_istream<char, _Traits>& __in, unsigned char (&__s)[_Num])
      |     ^~~~~~~~
/usr/include/c++/11/istream:868:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   mismatched types 'unsigned char [_Num]' and 'double(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:873:5: note: candidate: 'template<class _Traits, long unsigned int _Num> std::basic_istream<char, _Traits>& std::operator>>(std::basic_istream<char, _Traits>&, signed char (&)[_Num])'
  873 |     operator>>(basic_istream<char, _Traits>& __in, signed char (&__s)[_Num])
      |     ^~~~~~~~
/usr/include/c++/11/istream:873:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   mismatched types 'signed char [_Num]' and 'double(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/istream:1006:5: note: candidate: 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&)'
 1006 |     operator>>(_Istream&& __is, _Tp&& __x)
      |     ^~~~~~~~
/usr/include/c++/11/istream:1006:5: note:   template argument deduction/substitution failed:
/usr/include/c++/11/istream: In substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_istream<char>&; _Tp = double (&)(double) noexcept]':
chessboard.cpp:282:29:   required from here
/usr/include/c++/11/istream:1006:5: error: template constraint failure for 'template<class _Is, class _Tp>  requires (__derived_from_ios_base<_Is>) && requires(_Is& __is, _Tp&& __t) {__is >> (forward<_Tp>)(__t);} using __rvalue_stream_extraction_t = _Is&&'
/usr/include/c++/11/istream:1006:5: note: constraints not satisfied
In file included from /usr/include/c++/11/istream:39,
                 from /usr/include/c++/11/sstream:38,
                 from /usr/include/c++/11/complex:45,
                 from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/ostream: In substitution of 'template<class _Is, class _Tp>  requires (__derived_from_ios_base<_Is>) && requires(_Is& __is, _Tp&& __t) {__is >> (forward<_Tp>)(__t);} using __rvalue_stream_extraction_t = _Is&& [with _Is = std::basic_istream<char>&; _Tp = double (&)(double) noexcept]':
/usr/include/c++/11/istream:1006:5:   required by substitution of 'template<class _Istream, class _Tp> _Istream&& std::operator>>(_Istream&&, _Tp&&) [with _Istream = std::basic_istream<char>&; _Tp = double (&)(double) noexcept]'
chessboard.cpp:282:29:   required from here
/usr/include/c++/11/ostream:717:13:   required for the satisfaction of '__derived_from_ios_base<_Is>' [with _Is = std::basic_istream<char, std::char_traits<char> >&]
/usr/include/c++/11/ostream:717:39: note: the expression 'is_class_v<_Tp> [with _Tp = std::basic_istream<char, std::char_traits<char> >&]' evaluated to 'false'
  717 |     concept __derived_from_ios_base = is_class_v<_Tp>
      |                                       ^~~~~~~~~~~~~~~
In file included from /usr/include/c++/11/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:54,
                 from chessboard.cpp:1:
/usr/include/c++/11/complex:501:5: note: candidate: 'template<class _Tp, class _CharT, class _Traits> std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&, std::complex<_Tp>&)'
  501 |     operator>>(basic_istream<_CharT, _Traits>& __is, complex<_Tp>& __x)
      |     ^~~~~~~~
/usr/include/c++/11/complex:501:5: note:   template argument deduction/substitution failed:
chessboard.cpp:282:29: note:   mismatched types 'std::complex<_Tp>' and 'double(double) noexcept'
  282 |         cin >> x1[i] >> y1[i] >> x2[i] >> y2[i];
      |                             ^
In file included from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:66,
                 from chessboard.cpp:1:
/usr/include/c++/11/bitset:1472:5: note: candidate: 'template<class _CharT, class _Traits, long unsigned int _Nb> std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&, std::bitset<_Nb>&)'
 1472 |     operator>>(std::basic_istrea