結果
問題 | No.279 木の数え上げ |
ユーザー | swdamdr |
提出日時 | 2017-01-25 10:04:05 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
AC
|
実行時間 | 121 ms / 2,000 ms |
コード長 | 649 bytes |
コンパイル時間 | 2,098 ms |
コンパイル使用メモリ | 106,820 KB |
実行使用メモリ | 30,720 KB |
最終ジャッジ日時 | 2023-08-24 21:58:30 |
合計ジャッジ時間 | 4,871 ms |
ジャッジサーバーID (参考情報) |
judge12 / judge11 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 52 ms
23,464 KB |
testcase_01 | AC | 52 ms
21,316 KB |
testcase_02 | AC | 52 ms
21,296 KB |
testcase_03 | AC | 51 ms
19,192 KB |
testcase_04 | AC | 52 ms
21,256 KB |
testcase_05 | AC | 52 ms
21,288 KB |
testcase_06 | AC | 52 ms
21,380 KB |
testcase_07 | AC | 52 ms
21,272 KB |
testcase_08 | AC | 53 ms
23,336 KB |
testcase_09 | AC | 52 ms
21,340 KB |
testcase_10 | AC | 117 ms
28,560 KB |
testcase_11 | AC | 66 ms
23,840 KB |
testcase_12 | AC | 96 ms
29,500 KB |
testcase_13 | AC | 61 ms
23,476 KB |
testcase_14 | AC | 121 ms
28,908 KB |
testcase_15 | AC | 109 ms
26,176 KB |
testcase_16 | AC | 103 ms
25,860 KB |
testcase_17 | AC | 117 ms
30,640 KB |
testcase_18 | AC | 86 ms
27,040 KB |
testcase_19 | AC | 114 ms
30,720 KB |
testcase_20 | AC | 119 ms
28,912 KB |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System; using System.Linq; using System.Collections.Generic; class Program { static void Main(string[] args) { string s = Console.ReadLine(); int[] tree = new int[3]; for (int i = 0; i < s.Length; i++) { switch (s[i].ToString()) { case "t": tree[0]++; break; case "r": tree[1]++; break; case "e": tree[2]++; break; } } tree[2] /= 2; Console.WriteLine(tree.Min()); } }