結果

問題 No.1944 ∞
ユーザー 👑 obakyan
提出日時 2025-07-03 22:41:29
言語 Lua
(LuaJit 2.1.1734355927)
結果
WA  
実行時間 -
コード長 296 bytes
コンパイル時間 298 ms
コンパイル使用メモリ 7,976 KB
実行使用メモリ 7,844 KB
最終ジャッジ日時 2025-07-03 22:41:32
合計ジャッジ時間 2,836 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 36 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

n, x, y = io.read("*n", "*n", "*n")
a = {}
for i = 1, n do a[i] = io.read("*n") end
table.sort(a)
f = nil
if n == 1 then
  f = a[1] * a[1] == x * x + y * y
else
  r = -a[1]
  for i = 1, n do
    r = r + 2 * a[i]
  end
  f = 1LL * x * x + 1LL * y * y <= 1LL * r * r
end
print(f and "Yes" or "No")
0