Lets compare c and go: Hello_world.c :
#include
int main(){
printf(\"Hello world!\");
}
Hello_world.go:
By default gcc links dynamically and go - statically.
But if you link you C code statically, you might get a binary with a bigger size.
In my case:
both binaries are statically linked and without debug_info.
go build -ldflags="-s -w" -o test-go test.go
gcc -static -s -o test-c test.c