結果
| 問題 | No.313 π |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2015-12-08 23:05:28 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 427 bytes |
| 記録 | |
| コンパイル時間 | 1,386 ms |
| コンパイル使用メモリ | 166,516 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-09-14 20:25:16 |
| 合計ジャッジ時間 | 2,982 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge6 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 2 |
| other | WA * 32 |
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:20:29: warning: ‘e’ may be used uninitialized in this function [-Wmaybe-uninitialized]
20 | cout << b << " " << e << endl;
| ^
main.cpp:20:22: warning: ‘b’ may be used uninitialized in this function [-Wmaybe-uninitialized]
20 | cout << b << " " << e << endl;
| ^~~
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main() {
vector<int>VI{ 20104, 20063, 19892, 20011, 19874, 20199, 19898, 20163, 19956, 19841 };
char c;
map<char, long long int>MCL;
while( cin >> c )MCL[c]++;
int b, e;
for( auto x : MCL ) {
if( x.first != '.' ) {
auto y = x.first - '0';
if( VI[y]<x.second ) {
e = y;
} else if( VI[y]>x.second ) {
b = y;
}
}
}
cout << b << " " << e << endl;
}