結果
問題 | No.419 直角三角形 |
ユーザー |
![]() |
提出日時 | 2020-07-29 23:24:23 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 43 ms / 1,000 ms |
コード長 | 404 bytes |
コンパイル時間 | 284 ms |
コンパイル使用メモリ | 82,832 KB |
実行使用メモリ | 55,628 KB |
最終ジャッジ日時 | 2024-06-30 13:15:33 |
合計ジャッジ時間 | 2,005 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 |
ソースコード
import sys; input = sys.stdin.buffer.readlinesys.setrecursionlimit(10**7)from collections import defaultdictcon = 10 ** 9 + 7; INF = float("inf")def getlist():return list(map(int, input().split()))#処理内容def main():a, b = getlist()if a == b:print(a * (2 ** 0.5))returna, b = list(sorted([a, b]))ans = (b ** 2 - a ** 2) ** 0.5print(ans)if __name__ == '__main__':main()