program yukicoder_2842 use, intrinsic :: iso_fortran_env implicit none integer(int32) :: m, d read(input_unit, *) m, d write(output_unit, '(i0)') merge(23, 24, m < 8 .or. (m == 8 .and. d < 22)) end program yukicoder_2842