Submission #19459164


Source Code Expand

Copy
#include <bits/stdc++.h>
// #include <atcoder/all>
// #include "icld.cpp"
using namespace std;
using ll = long long int;
using pii = pair<int,int>;
using vi = vector<int>;
using vll = vector<ll>;
using vvi = vector<vector<int>>;
using ss = string;
using db = double;
const int dx[4] = {1,0,-1,0};
const int dy[4] = {0,1,0,-1};
//#define pi 3.14159265358979
#define rep(i,s,n) for(int i=(s);i<(int)(n);i++)
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
#define ci(x) cin >> (x)
#define cii(x) int (x);cin >> (x)
#define cci(x,y) int (x),(y);cin >> (x) >>(y)
#define co(x) cout << (x) << endl

int main(){
  cci(x,y);
  x--;
  int ax=x/4,bx=x/100,cx=x/400;  
  int ay=y/4,by=y/100,cy=y/400;  
  int allx=ax-bx+cx;
  int ally=ay-by+cy;  
  co(ally-allx);
}

Submission Info

Submission Time
Task C - 2月29日
User mayo031042
Language C++ (GCC 9.2.1)
Score 100
Code Size 806 Byte
Status AC
Exec Time 7 ms
Memory 3540 KB

Compile Error

./Main.cpp: In function ‘int main()’:
./Main.cpp:20:22: warning: unnecessary parentheses in declaration of ‘x’ [-Wparentheses]
   20 | #define cci(x,y) int (x),(y);cin >> (x) >>(y)
      |                      ^
./Main.cpp:24:3: note: in expansion of macro ‘cci’
   24 |   cci(x,y);
      |   ^~~
./Main.cpp:20:26: warning: unnecessary parentheses in declaration of ‘y’ [-Wparentheses]
   20 | #define cci(x,y) int (x),(y);cin >> (x) >>(y)
      |                          ^
./Main.cpp:24:3: note: in expansion of macro ‘cci’
   24 |   cci(x,y);
      |   ^~~

Judge Result

Set Name sub All
Score / Max Score 25 / 25 75 / 75
Status
AC × 10
AC × 22
Set Name Test Cases
sub test_01A.txt, test_02A.txt, test_03A.txt, test_04A.txt, test_05A.txt, test_07A.txt, test_09A.txt, test_11A.txt, test_13A.txt, test_15A.txt
All sample_01.txt, sample_02.txt, sample_03.txt, test_01A.txt, test_02A.txt, test_03A.txt, test_04A.txt, test_05A.txt, test_06.txt, test_07A.txt, test_08.txt, test_09A.txt, test_10.txt, test_11A.txt, test_12.txt, test_13A.txt, test_14.txt, test_15A.txt, test_16.txt, sample_01.txt, sample_02.txt, sample_03.txt
Case Name Status Exec Time Memory
sample_01.txt AC 7 ms 3428 KB
sample_02.txt AC 2 ms 3516 KB
sample_03.txt AC 2 ms 3512 KB
test_01A.txt AC 2 ms 3540 KB
test_02A.txt AC 2 ms 3520 KB
test_03A.txt AC 2 ms 3388 KB
test_04A.txt AC 2 ms 3424 KB
test_05A.txt AC 3 ms 3484 KB
test_06.txt AC 2 ms 3484 KB
test_07A.txt AC 2 ms 3384 KB
test_08.txt AC 2 ms 3428 KB
test_09A.txt AC 2 ms 3524 KB
test_10.txt AC 6 ms 3500 KB
test_11A.txt AC 2 ms 3420 KB
test_12.txt AC 2 ms 3384 KB
test_13A.txt AC 2 ms 3540 KB
test_14.txt AC 2 ms 3512 KB
test_15A.txt AC 1 ms 3428 KB
test_16.txt AC 2 ms 3516 KB