結果

問題 No.159 刺さらないUSB
ユーザー Ysmr_Ry
提出日時 2015-03-02 17:27:06
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 1 ms / 1,000 ms
コード長 178 bytes
コンパイル時間 112 ms
コンパイル使用メモリ 22,784 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-07-01 23:42:24
合計ジャッジ時間 808 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 18
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:7:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
    7 |         scanf( "%lf%lf", &p, &q );
      |         ~~~~~^~~~~~~~~~~~~~~~~~~~

ソースコード

diff #

// yukicoder 159 (http://yukicoder.me/problems/405)
#include<cstdio>

int main()
{
	double p, q;
	scanf( "%lf%lf", &p, &q );

	puts( (1-p)*q<p*(1-q)*q?"YES":"NO" );

	return 0;
}
0