結果
| 問題 |
No.35 タイパー高橋
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-02-25 20:08:04 |
| 言語 | Java (openjdk 23) |
| 結果 |
AC
|
| 実行時間 | 247 ms / 5,000 ms |
| コード長 | 549 bytes |
| コンパイル時間 | 3,664 ms |
| コンパイル使用メモリ | 76,396 KB |
| 実行使用メモリ | 58,640 KB |
| 最終ジャッジ日時 | 2024-10-01 11:26:34 |
| 合計ジャッジ時間 | 5,242 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 4 |
ソースコード
import java.util.Scanner;
public class No00000035_Main2 {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int typeCnt= 0;
int nonTypeCnt = 0;
int n = Integer.parseInt(scan.nextLine());
for(int i = 0; i < n; i++) {
int cnt = (12 * scan.nextInt()) /1000;
int strLength = scan.next().length();
if(strLength <= cnt) {
typeCnt += strLength;
} else {
typeCnt += cnt;
nonTypeCnt += strLength - cnt;
}
}
System.out.println(typeCnt + " " + nonTypeCnt);
scan.close();
}
}