A,B = gets.split.map(&:to_i) Q = [] A.times{|i| Q.push(i)} B.times{|i| Q.push(i)} puts Q.size