結果

問題 No.35 タイパー高橋
ユーザー fujitafujita
提出日時 2023-05-09 09:48:17
言語 C#
(.NET 8.0.203)
結果
WA  
実行時間 -
コード長 1,241 bytes
コンパイル時間 9,775 ms
コンパイル使用メモリ 144,548 KB
実行使用メモリ 164,308 KB
最終ジャッジ日時 2023-08-17 04:15:24
合計ジャッジ時間 10,613 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 49 ms
30,596 KB
testcase_01 WA -
testcase_02 WA -
testcase_03 AC 50 ms
164,308 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  Determining projects to restore...
  Restored /home/judge/data/code/main.csproj (in 152 ms).
.NET 向け Microsoft (R) Build Engine バージョン 17.0.0-preview-21470-01+cb055d28f
Copyright (C) Microsoft Corporation.All rights reserved.

  プレビュー版の .NET を使用しています。https://aka.ms/dotnet-core-preview をご覧ください
  main -> /home/judge/data/code/bin/Release/net6.0/main.dll
  main -> /home/judge/data/code/bin/Release/net6.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