<>=~('(.*)\s?'x4);print$1*$2%$4*$3%$4