結果
問題 | No.1422 Social Distance in Train |
ユーザー | megane_anko |
提出日時 | 2021-03-19 00:47:00 |
言語 | TypeScript (5.7.2) |
結果 |
AC
|
実行時間 | 64 ms / 2,000 ms |
コード長 | 204 bytes |
コンパイル時間 | 8,440 ms |
コンパイル使用メモリ | 228,484 KB |
実行使用メモリ | 39,552 KB |
最終ジャッジ日時 | 2024-12-31 16:35:10 |
合計ジャッジ時間 | 9,737 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 12 |
ソースコード
import * as fs from 'fs'; const input = fs.readFileSync('/dev/stdin', 'utf8'); const N = parseInt(input); if (N % 2 === 0) { console.log(N / 2 + 1); } else if (N % 2 !== 0) { console.log('1'); }