A, B = gets.split.map(&:to_i) ans = [] (0..B).each do |b| (0..A).each do |a| ans << a + b * 5 end end ans.delete(0) puts ans.uniq.sort