in reply to Sheer idle curiousity . . .
What does your intuition tell you this code does?
d=>sub{ $wait = 0 unless abs($wait); $wait = -34; },
In particular, abs returns the absolute value. The absolute value of -34 is 34, which is "true". Since your condition is never false, you never fall through to the action of the "unless" clause.
Dave
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Sheer idle curiousity . . .
by TheMonkWithoutVows (Novice) on Oct 23, 2013 at 22:16 UTC | |
|
Re^2: Sheer idle curiousity . . .
by boftx (Deacon) on Oct 23, 2013 at 22:08 UTC | |
by BrowserUk (Patriarch) on Oct 23, 2013 at 22:16 UTC | |
by boftx (Deacon) on Oct 23, 2013 at 22:26 UTC | |
by BrowserUk (Patriarch) on Oct 24, 2013 at 00:51 UTC |