use % instead of arithmetic hack for (PRO2)