home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / SASC6571.LZX / examples / nostartup / example_2 / hello.c < prev    next >
Encoding:
C/C++ Source or Header  |  1996-12-24  |  312 b   |  15 lines

  1. #include <string.h>
  2. #include <proto/dos.h>
  3. #include <proto/exec.h>
  4.  
  5. #define MSG "Hello, World!\n"
  6.  
  7. void hello(void)
  8. {
  9.    struct DosLibrary *DOSBase = 
  10.                       (struct DosLibrary *)OpenLibrary("dos.library", 0L);
  11.  
  12.    Write(Output(), MSG, strlen(MSG));
  13.  
  14.    CloseLibrary((struct Library *)DOSBase);
  15. }