結果
問題 | No.1499 羊が、何匹だっけ |
ユーザー | tenten |
提出日時 | 2021-05-10 11:03:26 |
言語 | Java21 (openjdk 21) |
結果 |
AC
|
実行時間 | 60 ms / 2,000 ms |
コード長 | 1,047 bytes |
コンパイル時間 | 4,542 ms |
コンパイル使用メモリ | 77,124 KB |
実行使用メモリ | 53,388 KB |
最終ジャッジ日時 | 2023-10-19 19:33:11 |
合計ジャッジ時間 | 6,499 ms |
ジャッジサーバーID (参考情報) |
judge14 / judge15 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 55 ms
53,360 KB |
testcase_01 | AC | 55 ms
52,408 KB |
testcase_02 | AC | 57 ms
52,436 KB |
testcase_03 | AC | 60 ms
53,376 KB |
testcase_04 | AC | 58 ms
52,488 KB |
testcase_05 | AC | 59 ms
53,384 KB |
testcase_06 | AC | 56 ms
53,368 KB |
testcase_07 | AC | 55 ms
53,368 KB |
testcase_08 | AC | 56 ms
53,376 KB |
testcase_09 | AC | 59 ms
53,388 KB |
testcase_10 | AC | 56 ms
52,432 KB |
ソースコード
import java.io.*; import java.util.*; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(); int n = sc.nextInt(); StringBuilder sb = new StringBuilder(); for (int i = 0; i < n; i++) { sb.append(sc.next()).append(" ").append(sc.next()).append(" ").append(sc.nextInt() + 1).append(" ").append(sc.next()).append("\n"); } System.out.print(sb); } } class Scanner { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(""); public Scanner() throws Exception { } public int nextInt() throws Exception { return Integer.parseInt(next()); } public long nextLong() throws Exception { return Long.parseLong(next()); } public String next() throws Exception { if (!st.hasMoreTokens()) { st = new StringTokenizer(br.readLine()); } return st.nextToken(); } }