結果
| 問題 |
No.419 直角三角形
|
| コンテスト | |
| ユーザー |
vjudge1
|
| 提出日時 | 2024-12-22 13:08:44 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 274 bytes |
| コンパイル時間 | 553 ms |
| コンパイル使用メモリ | 37,888 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-12-22 13:08:46 |
| 合計ジャッジ時間 | 1,366 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 20 |
ソースコード
#include<cstdio>
#include<cmath>
using namespace std;
int main() {
//freopen("triangle.in","r",stdin);
//freopen("triangle.out","w",stdout);
int a,b; scanf("%d %d",&a,&b);
if(a==b) printf("%.8lf",sqrt(2*a*a));
else printf("%.8lf",sqrt(abs(a*a-b*b)));
return 0;
}
vjudge1