結果

問題 No.35 タイパー高橋
ユーザー fujitafujita
提出日時 2023-05-09 09:48:17
言語 C#
(.NET 8.0.203)
結果
WA  
実行時間 -
コード長 1,241 bytes
コンパイル時間 9,998 ms
コンパイル使用メモリ 166,340 KB
実行使用メモリ 184,436 KB
最終ジャッジ日時 2024-05-04 11:20:49
合計ジャッジ時間 10,387 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 51 ms
29,056 KB
testcase_01 WA -
testcase_02 WA -
testcase_03 AC 52 ms
184,436 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.csproj を復元しました (102 ms)。
MSBuild のバージョン 17.9.6+a4ecab324 (.NET)
  main -> /home/judge/data/code/bin/Release/net8.0/main.dll
  main -> /home/judge/data/code/bin/Release/net8.0/publish/

ソースコード

diff #

using System;

namespace yukicoder
{
    class Program
    {

        static void Main(string[] args)
        {
            int N = int.Parse(Console.ReadLine());
            int type = 0 , losstype = 0 , num = 0;

            string[] strings = new string[N];

            //1文字のタイピング時間
            int n = 1000 / 12;
            double m = ((1000 % 12) - 1) * 0.1;
            double sum = n + m;

            for (int i= 0; i < N; i++)
            {
                var str = Console.ReadLine();
                var g = str.Split(" ");
                strings[0] = g[0];//入力された文字を配列に
                strings[1] = g[1];
                
                
                num = int.Parse(strings[0]);

                if (num > strings[1].Length * sum)
                {
                    type += strings[1].Length;
                }
                else
                {
                    int temp = (int)(num / sum);//一時受け取り

                    type = (int)(type + (num / sum));
                    losstype = losstype + (strings[1].Length - temp);//1行分のミスタイプ
                }
            }
            Console.WriteLine(type + " " + losstype);
        }
    }
}
0