提出 #71402091
ソースコード 拡げる
let dataReceived = '';
process.stdin.on('data', (data) => {
dataReceived += data;
for (; ;) {
const newLinePos = dataReceived.indexOf('\n');
if (newLinePos >= 0) {
const line = dataReceived.substring(0, newLinePos);
dataReceived = dataReceived.substring(newLinePos + 1);
const [H, B] = line.split(' ').map((v) => parseInt(v, 10));
const ans = Math.max(H - B, 0);
process.stdout.write(`${ans}\n`);
} else {
break;
}
}
});
提出情報
| 提出日時 | |
|---|---|
| 問題 | A - Robot Balance |
| ユーザ | mikecat |
| 言語 | JavaScript (Node.js 22.19.0) |
| 得点 | 100 |
| コード長 | 497 Byte |
| 結果 | AC |
| 実行時間 | 40 ms |
| メモリ | 42740 KiB |
ジャッジ結果
| セット名 | Sample | All | ||||
|---|---|---|---|---|---|---|
| 得点 / 配点 | 0 / 0 | 100 / 100 | ||||
| 結果 |
|
|
| セット名 | テストケース |
|---|---|
| Sample | 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt |
| All | 00_sample_00.txt, 00_sample_01.txt, 00_sample_02.txt, 01_random_03.txt, 01_random_04.txt, 01_random_05.txt, 01_random_06.txt, 01_random_07.txt, 01_random_08.txt, 01_random_09.txt, 01_random_10.txt, 01_random_11.txt |
| ケース名 | 結果 | 実行時間 | メモリ |
|---|---|---|---|
| 00_sample_00.txt | AC | 40 ms | 42512 KiB |
| 00_sample_01.txt | AC | 28 ms | 42612 KiB |
| 00_sample_02.txt | AC | 27 ms | 42568 KiB |
| 01_random_03.txt | AC | 27 ms | 42740 KiB |
| 01_random_04.txt | AC | 26 ms | 42620 KiB |
| 01_random_05.txt | AC | 27 ms | 42612 KiB |
| 01_random_06.txt | AC | 27 ms | 42732 KiB |
| 01_random_07.txt | AC | 26 ms | 42612 KiB |
| 01_random_08.txt | AC | 27 ms | 42560 KiB |
| 01_random_09.txt | AC | 28 ms | 42732 KiB |
| 01_random_10.txt | AC | 29 ms | 42724 KiB |
| 01_random_11.txt | AC | 29 ms | 42636 KiB |