a,b,c,d=map(int,input().split()) wakeup_min=c+(a-1)*d print(b) print(wakeup_min)