[cap-talk] C vs. Safety
Toby Murray
toby.murray at comlab.ox.ac.uk
Thu Aug 7 19:46:05 CDT 2008
On Thu, 2008-08-07 at 17:18 -0700, Tony Bartoletti wrote:
> At 05:07 PM 8/7/2008, you wrote:
> >Surely (assuming arbitrary precision integer arithmetic) termination
> >here can be proved as follows.
> >
> >Unwind the loop once to arrive at
> >
> >// invariant: k is even or k == 1
>
> False.
>
> Let N = 7:
> then k becomes (3*7 + 1)/2 = 11.
>
This demonstrates why doing this stuff after 1am is not a good idea...
Sorry for the bogosity...
More information about the cap-talk
mailing list