Created
March 29, 2012 00:44
-
-
Save jessta/2231926 to your computer and use it in GitHub Desktop.
Go hello word binary size
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
int main(){ | |
write(1, "hello world\n", 12); | |
} | |
/* | |
[jessta@book ~]$ gcc -static -Os hello.c | |
[jessta@book ~]$ du -h ./a.out | |
636K ./a.out | |
*/ |
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
package main | |
import "os" | |
func main() { | |
os.Stdout.Write([]byte("hello world")) | |
} | |
/* | |
[jessta@book ~]$ go build hello.go | |
[jessta@book ~]$ du -h ./hello | |
544K ./hello | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment