Divide with remainders