結果
| 問題 |
No.35 タイパー高橋
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-07-16 20:46:03 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 4 ms / 5,000 ms |
| コード長 | 464 bytes |
| コンパイル時間 | 589 ms |
| コンパイル使用メモリ | 58,204 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-08 04:28:56 |
| 合計ジャッジ時間 | 971 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 4 |
ソースコード
#include <iostream>
#include <string>
#include <algorithm>
using namespace std;
int main()
{
int n, t[1000];
string s[1000];
cin >> n;
for(int i=0; i<n; i++) cin >> t[i] >> s[i];
int pos = 0, imp = 0;
for(int i=0; i<n; i++){
int lim = 12 * t[i] / 1000;
int len = s[i].length();
pos += len < lim ? len : lim;
imp += len < lim ? 0 : len - lim;
}
cout << pos << " " << imp << endl;
return 0;
}