[erlang-questions] Unexpected behaviour of timer:sleep

Chandru chandrashekhar.mullaparthi@REDACTED
Wed Mar 19 12:42:03 CET 2008


On 19/03/2008, Chandru <chandrashekhar.mullaparthi@REDACTED> wrote:
>
> On 19/03/2008, shehan <shehan@REDACTED> wrote:
> >
> >  Hi all,
> >
> > When I am running following command, unexpected value came as result.
> > Why is that??
> >
> >
> >
> > (test@REDACTED)15> timer:tc(timer, sleep, [1]).
> >
> > {15000,ok}
> > I expected value is, between 1000 to 2000.
> >
>
> timer:tc returns the elapsed time in microseconds, so it is within your
> expectation!
>
> Chandru
>

Sorry - I wrote gibberish in my previous message.

You should expect some value greater than 1000, not necessarily lesser than
2000.

Chandru
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20080319/211b1827/attachment.htm>


More information about the erlang-questions mailing list