-
-
Save bostwick/8ee1d4df9c7743f9efed to your computer and use it in GitHub Desktop.
Timing HelloWorld in Java, Ruby and Python
This file contains 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
[daniel@Daniel-Bostwicks-MacBook-Pro Sandbox]$ time java -client HelloWorld | |
Hello World! | |
real 0m0.182s | |
user 0m0.204s | |
sys 0m0.029s | |
[daniel@Daniel-Bostwicks-MacBook-Pro Sandbox]$ time ruby hello_world.rb | |
Hello World! | |
real 0m0.023s | |
user 0m0.019s | |
sys 0m0.004s | |
[daniel@Daniel-Bostwicks-MacBook-Pro Sandbox]$ time python hello_world.py | |
Hello World! | |
real 0m0.067s | |
user 0m0.056s | |
sys 0m0.010s | |
[daniel@Daniel-Bostwicks-MacBook-Pro Sandbox]$ cat HelloWorld.java hello_world.rb hello_world.py | |
public class HelloWorld { | |
public static void main(String[] args) { | |
System.out.println("Hello World!"); | |
} | |
} | |
puts "Hello World!" | |
print "Hello World!" | |
[daniel@Daniel-Bostwicks-MacBook-Pro Sandbox]$ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment