changed -p to an int