結果
問題 | No.656 ゴルフ |
ユーザー | No |
提出日時 | 2018-03-02 22:26:53 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
AC
|
実行時間 | 55 ms / 2,000 ms |
コード長 | 555 bytes |
コンパイル時間 | 4,185 ms |
コンパイル使用メモリ | 99,380 KB |
実行使用メモリ | 22,820 KB |
最終ジャッジ日時 | 2023-09-03 22:48:31 |
合計ジャッジ時間 | 3,621 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge11 |
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 53 ms
20,756 KB |
testcase_01 | AC | 53 ms
22,624 KB |
testcase_02 | AC | 52 ms
22,796 KB |
testcase_03 | AC | 48 ms
20,444 KB |
testcase_04 | AC | 52 ms
22,820 KB |
testcase_05 | AC | 52 ms
22,724 KB |
testcase_06 | AC | 55 ms
20,744 KB |
testcase_07 | AC | 54 ms
20,744 KB |
testcase_08 | AC | 52 ms
20,716 KB |
testcase_09 | AC | 51 ms
20,612 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; namespace y { class Program { static void Main(string[] args) { var a = Console.ReadLine(); int ans = 0; foreach (var item in a) { if (item == '0') { ans += 10; } else { ans += int.Parse(item.ToString()); } } Console.WriteLine(ans); } } }