結果
問題 | No.188 HAPPY DAY |
ユーザー |
![]() |
提出日時 | 2015-04-23 22:19:57 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 1,195 bytes |
コンパイル時間 | 859 ms |
コンパイル使用メモリ | 82,048 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-30 20:11:06 |
合計ジャッジ時間 | 1,280 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 1 |
ソースコード
#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;}