 line = readlines.map(&:to_i)
  
   if line[0] == 1 && line[1] == 2　then
   print 3
   elsif line[0] == 1 && line[1] == 3 then
   print 2
   elsif line[0] == 2 && line[1] == 3 then 
    print 1
  end
 
 
~
~