> Here's the problem, you're in the wrong millennium! year !=3D 10 ; year = =3D=20 > 2010 > > Now it will work out to 319. (N3 =3D 2) I tried it that way first (1 + INT(2010 - (4 * (INT(2010/4) + 2)/3))) Working from inside out INT(2010/4) + 2 =3D 504 * 4 =3D 2016 /3 =3D 672 N3 =3D 1 + INT(2010 - 672) =3D 1339 If N1 =3D 336 and N2 =3D 1 N =3D 336 - (1 * 1339) + 15 - 30 =3D - 1005 ? (I think) Joe=20 --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .