結果
問題 | No.35 タイパー高橋 |
ユーザー | kano_town |
提出日時 | 2014-11-21 15:00:05 |
言語 | Java21 (openjdk 21) |
結果 |
AC
|
実行時間 | 229 ms / 5,000 ms |
コード長 | 467 bytes |
コンパイル時間 | 3,502 ms |
コンパイル使用メモリ | 76,056 KB |
実行使用メモリ | 61,228 KB |
最終ジャッジ日時 | 2023-08-30 22:09:34 |
合計ジャッジ時間 | 4,868 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge11 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 221 ms
61,212 KB |
testcase_01 | AC | 217 ms
60,960 KB |
testcase_02 | AC | 228 ms
61,056 KB |
testcase_03 | AC | 229 ms
61,228 KB |
ソースコード
import java.util.Scanner; public class Yukicoder35 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(), T; String S; int ok = 0, ng = 0, type; for (int i = 0; i < N; i++) { T = sc.nextInt(); S = sc.next(); type = (int) (12.0 * (double) T / 1000.0); ok += Math.min(S.length(), type); ng += Math.max(S.length() - type, 0); } System.out.println(ok + " " + ng); } }