結果
| 問題 | 
                            No.512 魔法少女の追いかけっこ
                             | 
                    
| コンテスト | |
| ユーザー | 
                             ooh_21
                         | 
                    
| 提出日時 | 2017-06-01 17:57:42 | 
| 言語 | C#(csc)  (csc 3.9.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 1,695 bytes | 
| コンパイル時間 | 1,337 ms | 
| コンパイル使用メモリ | 106,624 KB | 
| 実行使用メモリ | 19,200 KB | 
| 最終ジャッジ日時 | 2024-06-27 06:32:02 | 
| 合計ジャッジ時間 | 3,736 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge5 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 11 WA * 42 | 
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace pj12
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] speed = Console.ReadLine().Trim().Split(' ').Select(x => int.Parse(x)).ToArray();
            speed[0] = speed[0] * 1000 / 60 / 60;
            speed[1] = speed[1] * 1000 / 60 / 60;
            int coner = int.Parse(Console.ReadLine());
            String look = "Yes";
            int[] road = new int[coner];
            int[] line = Console.ReadLine().Trim().Split(' ').Select(x => int.Parse(x)).ToArray();
            
            for(int i = 0;i < coner;i++)
            {
                road[i] = line[i];
            }
            int nowX = 0, nowY = 0;
            for(int i = 0;i < coner;i++)
            {
                for (int j = 0; j < coner;j++ )
                {
                    if(speed[0] <= 0)
                    {
                        nowX = j;
                    }
                    else
                    {
                        speed[0] -= road[j];
                    }
                    if (speed[1] <= 0)
                    {
                        nowY = j;
                    }
                    else
                    {
                        speed[1] -= road[j];
                    }
                    if(nowX - nowY > 1)
                    {
                        look = "NO";
                        break;
                    }
                }
                speed[0] += speed[0];
                speed[1] += speed[1];
            }
            Console.WriteLine(look);
        }
    }
}
            
            
            
        
            
ooh_21