9p / who / tweedy / 9C / 1


The first C program (hello, world)

Code

#include <u.h>
#include <libc.h>

void
main()
{
    print("Hello, world ☺\n");

    exits(0);
}

Output

$ 9c hello.c
$ 9l hello.o -o hello
$ ./hello
Hello, world ☺



tweedy