結果

問題 No.3151 natural math of inscribed circle
ユーザー ゼット
提出日時 2025-05-20 21:30:24
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 69 ms / 2,000 ms
コード長 443 bytes
コンパイル時間 188 ms
コンパイル使用メモリ 82,080 KB
実行使用メモリ 76,228 KB
最終ジャッジ日時 2025-06-20 02:58:42
合計ジャッジ時間 4,219 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 41
権限があれば一括ダウンロードができます

ソースコード

diff #

u=[1]*10**6
u2=[1]*(10**6)
mod=998244353
for i in range(1,10**6):
  u[i]=u[i-1]*i
  u[i]%=mod
u2[10**6-1]=pow(u[10**6-1],-1,mod)
for i in range(10**6-2,0,-1):
  u2[i]=u2[i+1]*(i+1)
  u2[i]%=mod
def ncm(x,y):
  if y>x or y<0:
    return 0
  ans=u[x]*u2[y]
  ans%=mod
  ans*=u2[x-y]
  ans%=mod
  return ans
from math import sqrt
a,b,c=map(int,input().split())
x=(a**2+b**2-c**2)/(2*a*b)
y=sqrt(1-x**2)
S=a*b*y/2
result=2*S/(a+b+c)
print(result)
0