Re: delay loop

new topic     » goto parent     » topic index » view thread      » older message » newer message

EX: 4783
EXW: 1755
With PEU recompiled with BCC I get 858993459. But this seems to be a bug :)

Winchip 200 Mhz

    Martin

> Please, could anyone with cpu over 1000mhz. tell me the output of the
> following?
> ... 3515 on P166.
> 
> --
> include get.e
> atom tick,ti,z,x tick=0 ti=time()
> while time()-ti < .5 do
> tick+=1 z=power(56.982,7.3)/tick
> end while
> function abs(object a)
> if a<0 then return-a else return a end if
> end function
> procedure soft_delay()
> for i = 1 to 2 + abs(tick/2400) do
> z=power(56.982,7.3)/i end for
> end procedure
> x=0 ti=time()
> while time()-ti < 5 do
> soft_delay() soft_delay()
> x += 1 end while
> printf(1,"%d %s\n",{x/5,":done, any key exits"})
> z=wait_key()
> --
> TIA, Wolf

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu