Submission #4652278


Source Code Expand

program othello
  implicit none
  integer :: n, q, p(0:200001), l, r, i
  p = 0
  read(*,*) n, q
  do i = 1, q
    read(*,*) l, r
    p(l) = p(l) + 1
    p(r+1) = p(r+1) - 1
  end do
  do i = 1, n
    p(i) = p(i) + p(i-1)
  end do
  do i = 1, n
    p(i) = mod(p(i),2)
  end do
  do i = 1, n
    write(*,'(i0)',advance='no') p(i)
  end do
  write(*,*)
end program othello

Submission Info

Submission Time
Task C - オセロ
User ue1221
Language Fortran (gfortran v4.8.4)
Score 100
Code Size 390 Byte
Status AC
Exec Time 174 ms
Memory 1536 KB

Judge Result

Set Name Sample Subtask1 All
Score / Max Score 0 / 0 60 / 60 40 / 40
Status
AC × 2
AC × 12
AC × 34
Set Name Test Cases
Sample 00_example_01.txt, 00_example_02.txt
Subtask1 00_example_01.txt, 00_example_02.txt, 10_small_01.txt, 10_small_02.txt, 10_small_03.txt, 10_small_04.txt, 10_small_05.txt, 10_small_06.txt, 10_small_07.txt, 10_small_08.txt, 10_small_09.txt, 10_small_10.txt
All 00_example_01.txt, 00_example_02.txt, 10_small_01.txt, 10_small_02.txt, 10_small_03.txt, 10_small_04.txt, 10_small_05.txt, 10_small_06.txt, 10_small_07.txt, 10_small_08.txt, 10_small_09.txt, 10_small_10.txt, 20_rand_01.txt, 20_rand_02.txt, 20_rand_03.txt, 20_rand_04.txt, 20_rand_05.txt, 20_rand_06.txt, 20_rand_07.txt, 20_rand_08.txt, 20_rand_09.txt, 20_rand_10.txt, 30_max_01.txt, 30_max_02.txt, 30_max_03.txt, 30_max_04.txt, 30_max_05.txt, 40_corner_01.txt, 40_corner_02.txt, 40_corner_03.txt, 40_corner_04.txt, 40_corner_05.txt, 40_corner_06.txt, 40_corner_07.txt
Case Name Status Exec Time Memory
00_example_01.txt AC 7 ms 1536 KB
00_example_02.txt AC 1 ms 1024 KB
10_small_01.txt AC 2 ms 1024 KB
10_small_02.txt AC 1 ms 1024 KB
10_small_03.txt AC 1 ms 1024 KB
10_small_04.txt AC 1 ms 1024 KB
10_small_05.txt AC 1 ms 1024 KB
10_small_06.txt AC 1 ms 1024 KB
10_small_07.txt AC 1 ms 1024 KB
10_small_08.txt AC 1 ms 1024 KB
10_small_09.txt AC 1 ms 1024 KB
10_small_10.txt AC 1 ms 1024 KB
20_rand_01.txt AC 71 ms 1024 KB
20_rand_02.txt AC 19 ms 1024 KB
20_rand_03.txt AC 32 ms 1152 KB
20_rand_04.txt AC 42 ms 1024 KB
20_rand_05.txt AC 17 ms 1024 KB
20_rand_06.txt AC 46 ms 1024 KB
20_rand_07.txt AC 32 ms 1152 KB
20_rand_08.txt AC 7 ms 1024 KB
20_rand_09.txt AC 23 ms 1024 KB
20_rand_10.txt AC 16 ms 1024 KB
30_max_01.txt AC 164 ms 1152 KB
30_max_02.txt AC 165 ms 1152 KB
30_max_03.txt AC 164 ms 1152 KB
30_max_04.txt AC 164 ms 1152 KB
30_max_05.txt AC 165 ms 1152 KB
40_corner_01.txt AC 85 ms 1024 KB
40_corner_02.txt AC 153 ms 1152 KB
40_corner_03.txt AC 155 ms 1152 KB
40_corner_04.txt AC 174 ms 1152 KB
40_corner_05.txt AC 140 ms 1152 KB
40_corner_06.txt AC 85 ms 1024 KB
40_corner_07.txt AC 158 ms 1152 KB