結果

問題 No.188 HAPPY DAY
ユーザー kakira9618kakira9618
提出日時 2015-04-23 22:19:57
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 1 ms / 1,000 ms
コード長 1,195 bytes
コンパイル時間 569 ms
コンパイル使用メモリ 82,228 KB
実行使用メモリ 4,376 KB
最終ジャッジ日時 2023-08-29 01:54:38
合計ジャッジ時間 937 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <map>
#include <set>
#include <list>
#include <cmath>
#include <queue>
#include <stack>
#include <cstdio>
#include <string>
#include <vector>
#include <complex>
#include <cstdlib>
#include <cstring>
#include <numeric>
#include <sstream>
#include <iostream>
#include <algorithm>
#include <functional>
  
#define mp       make_pair
#define pb       push_back
#define all(x)   (x).begin(),(x).end()
#define rep(i,n) for(int i=0;i<(n);i++)
  
using namespace std;
  
typedef    long long          ll;
typedef    unsigned long long ull;
typedef    vector<bool>       vb;
typedef    vector<int>        vi;
typedef    vector<vb>         vvb;
typedef    vector<vi>         vvi;
typedef    pair<int,int>      pii;
  
const int INF=1<<29;
const double EPS=1e-9;
  
const int dx[]={1,0,-1,0,1,1,-1,-1},dy[]={0,-1,0,1,1,-1,-1,1};


int main() {
    int day;

    int maxday[] = {0,31,28,31,30,31,30,31,31,30,31,30,31};

    int count = 0;
    for (int month = 1; month <= 12; month++) {
        int m = maxday[month];
        for (int j = 1; j <= m; j++) {
            if (month == j / 10 + j % 10) {
                count++;
            }
        }
    }
    cout << count << endl;
    return 0;
}
0