Checking for zero in modulo