結果
| 問題 |
No.419 直角三角形
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2018-11-22 01:47:09 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 311 bytes |
| コンパイル時間 | 576 ms |
| コンパイル使用メモリ | 65,792 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-12-24 16:12:30 |
| 合計ジャッジ時間 | 1,355 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 17 WA * 3 |
ソースコード
#include<iostream>
#include<string>
#include<math.h>
#include<iomanip>
using namespace std;
int main() {
double a, b;
cin >> a >> b;
if (a > b)cout <<fixed<<setprecision(10)<< sqrt(pow(a, 2) - pow(b,2))<<endl;
else if (a < b)cout <<fixed<<setprecision(10)<< sqrt(pow(b,2)-pow(a,2))<<endl;
return 0;
}