Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

In this thread, we Hello World

Name: Anonymous 2006-06-20 20:56

c:
#include <stdio.h>
main() { printf("hey worldz\n"); }

Name: Anonymous 2006-08-17 11:20

Hello World for Win32:

#define UNICODE
#include <windows.h>

int APIENTRY WinMain(HINSTANCE hInstance,
                     HINSTANCE hPrevInstance,
                     LPSTR lpCmdLine,
                     int nCmdShow) {

    HANDLE stdin, stdout;
    TCHAR *msg = L"Hello, world!";

    AllocConsole();
    stdin = GetStdHandle(STD_INPUT_HANDLE);
    stdout = GetStdHandle(STD_OUTPUT_HANDLE);
   
    WriteConsole(stdout, msg, 12, NULL, NULL);
    ReadConsole(stdin, NULL, 0, NULL, NULL);
   
    FreeConsole();
    ExitProcess(0);
    return 0;
}

Clearly, "OS API" is to "Win32" what "programming language" is to "Java".

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List