結果
| 問題 | No.857 素振り |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-02-15 18:22:29 |
| 言語 | TypeScript (6.0.2) |
| 結果 |
AC
|
| 実行時間 | 90 ms / 1,000 ms |
| コード長 | 360 bytes |
| 記録 | |
| コンパイル時間 | 4,603 ms |
| コンパイル使用メモリ | 347,688 KB |
| 実行使用メモリ | 53,356 KB |
| 最終ジャッジ日時 | 2026-06-05 05:04:05 |
| 合計ジャッジ時間 | 6,574 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 8 |
ソースコード
import * as fs from 'fs';
const input = fs.readFileSync('/dev/stdin', 'utf8');
const arr = input.split(/[ \n]/);
let X = BigInt(arr[0]);
let Y = BigInt(arr[1]);
let Z = BigInt(arr[2]);
if (Y <= Z) {
console.log(String(Z - BigInt(2)));
} else if (X <= Z && Z < Y) {
console.log(String(Z - BigInt(1)));
} else if (Z < X) {
console.log(String(Z));
}