Ron Ford wrote:
(snip, I wrote)
>>As far as the original question, I believe it is
>>one fourth, not one eighth.
(snip)
> How did we miss half of the cases?
(snip)
> %%- INT_MAX is 7. UB is invoked when the values are:
> %%-
> %%- 7 and any of -1, -2, -3, -4, -5, -6, -7, -8
> %%- 6 and any of -2, -3, -4, -5, -6, -7, -8
> %%- 5 and any of -3, -4, -5, -6, -7, -8
> %%- 4 and any of -4, -5, -6, -7, -8
> %%- 3 and any of -5, -6, -7, -8
> %%- 2 and any of -6, -7, -8
> %%- 1 and any of -7, -8
> %%- 0 and -8
The other half are negative numbers minus positive numbers,
with the result below -8.
-- glen