結果
| 問題 |
No.419 直角三角形
|
| コンテスト | |
| ユーザー |
btk
|
| 提出日時 | 2016-09-09 23:59:36 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 3 ms / 1,000 ms |
| コード長 | 252 bytes |
| コンパイル時間 | 1,742 ms |
| コンパイル使用メモリ | 168,552 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-16 18:48:45 |
| 合計ジャッジ時間 | 2,410 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 20 |
ソースコード
#include<bits/stdc++.h>
using namespace std;
int main(){
double a,b,x,y;cin>>a>>b;
tie(x,y)=minmax(a,b);
cout<<fixed;
cout<<setprecision(10);
if(x==y)cout<<sqrt(x*x+y*y)<<endl;
else cout<<sqrt(y*y-x*x)<<endl;
return 0;
}
btk