while 1:a,b=input().split();i=10;exec("i-=%s