Created
September 26, 2012 17:14
-
-
Save bduggan/3789274 to your computer and use it in GitHub Desktop.
sleep
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use Mojo::IOLoop; | |
use feature 'say'; | |
Mojo::IOLoop->timer(5 => sub { | |
say "It has been 5 seconds, it is now ".localtime; | |
} ); | |
say "It is now ".localtime; | |
Mojo::IOLoop->start; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use feature 'say'; | |
say "The time is ".localtime; | |
sleep 5; | |
say "It has been 5 seconds, the time is ".localtime; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment