while~0:m="mysterious";a=raw_input().split(" + ");print m*(m in a)or sum(eval(e,{m:0})for e in a)