divide with bit manipulation