結果

問題 No.199 星を描こう
ユーザー n_knuu
提出日時 2019-05-06 22:25:35
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 1,517 ms / 2,000 ms
コード長 349 bytes
コンパイル時間 281 ms
コンパイル使用メモリ 12,032 KB
実行使用メモリ 68,016 KB
最終ジャッジ日時 2025-04-22 13:53:30
合計ジャッジ時間 7,005 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
外部呼び出し有り
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 25
権限があれば一括ダウンロードができます

ソースコード

diff #

import numpy as np
from scipy.spatial import ConvexHull
from scipy.spatial.qhull import QhullError

points = []
for _ in range(5):
    x, y = map(int, input().split())
    points.append([x, y])
points = np.asarray(points)
try:
    hull = ConvexHull(points)
except QhullError:
    print("NO")
    quit()

print("YES" if hull.nsimplex == 5 else "NO")
0