結果

問題 No.35 タイパー高橋
ユーザー Yut176Yut176
提出日時 2016-10-04 20:31:48
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 3 ms / 5,000 ms
コード長 541 bytes
コンパイル時間 692 ms
コンパイル使用メモリ 71,916 KB
実行使用メモリ 4,384 KB
最終ジャッジ日時 2023-08-13 22:46:11
合計ジャッジ時間 1,233 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

#include<iostream>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<vector>
#include<map>
#include<queue>
#include<string>
#include<sstream>
#include<cmath>
using namespace std;


int main(){

  int n;
  cin >> n;
  int t;
  string s;
  int cnt[2] = {0,0};
  double tmp = 1000 / 12;
  for(int i=0; i<n; i++){
    cin >> t >> s;
    int a = 12 * t / 1000;
    if( a >= s.size() ) cnt[0]+= s.size();
    else{
      cnt[0] += a;
      cnt[1] += s.size()-a;
    }

  }
  cout << cnt[0] << " " << cnt[1] << endl;



  return 0;
}
0