結果

問題 No.159 刺さらないUSB
ユーザー mban
提出日時 2016-11-07 09:41:36
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 25 ms / 1,000 ms
コード長 417 bytes
コンパイル時間 1,373 ms
コンパイル使用メモリ 103,424 KB
実行使用メモリ 17,920 KB
最終ジャッジ日時 2024-07-02 00:00:44
合計ジャッジ時間 2,049 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 18
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Collections.Generic;
using System.Linq;

class Magatro
{
    static void Main()
    {
        string[] s = Console.ReadLine().Split(' ');
        double p, q;
        p = double.Parse(s[0]);
        q = double.Parse(s[1]);
        double P1, P2;
        P1 = (1.0 - p) * q;
        P2 = p * (1.0 - q) * q;
        string ans = P1 < P2 ? "YES" : "NO";
        Console.WriteLine(ans);
    }
}
0