結果
| 問題 | No.3039 配信者 |
| コンテスト | |
| ユーザー |
lotoka
|
| 提出日時 | 2026-07-15 13:34:51 |
| 言語 | Fortran (gFortran 16.1.0) |
| 結果 |
AC
|
| 実行時間 | 371 ms / 2,000 ms |
| + 629µs | |
| コード長 | 472 bytes |
| 記録 | |
| コンパイル時間 | 325 ms |
| コンパイル使用メモリ | 39,808 KB |
| 実行使用メモリ | 6,400 KB |
| 最終ジャッジ日時 | 2026-07-15 13:35:02 |
| 合計ジャッジ時間 | 7,108 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 15 |
ソースコード
program main
integer n, h, a, b, i, watching, maximum
integer, allocatable, dimension(:) :: watch
read *, n, h
allocate(watch(h+1))
watch = 0
do i = 1, n
read *, a, b
watch(a+1) = watch(a+1) + 1
watch(b+2) = watch(b+2) - 1
end do
watching = 0
maximum = 0
do i = 1, h
watching = watching + watch(i)
maximum = max(maximum, watching)
end do
write (6, fmt='(I0)') maximum
end program main
lotoka