結果
| 問題 |
No.419 直角三角形
|
| コンテスト | |
| ユーザー |
eve__fuyuki
|
| 提出日時 | 2018-03-14 01:34:52 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 290 bytes |
| コンパイル時間 | 805 ms |
| コンパイル使用メモリ | 65,140 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-24 13:15:17 |
| 合計ジャッジ時間 | 1,352 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 20 |
ソースコード
#include<iostream>
#include<cstdio>
#include<iomanip>
#include<cmath>
using namespace std;
int main(){
int a,b,buf;
double ans;
cin >> a >> b;
if(a == b) ans = a*sqrt(2.0);
else{
ans = sqrt((double)abs(a*a-b*b));
}
printf("%.8lf\n",ans);
return 0;
}
eve__fuyuki