A, B = gets.split.map &:to_i puts (0..B).flat_map{|i| [*i*5..i*5+A] }[1..-1].uniq