home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / Misc / M2V11-2.LHA / modula / dice / dice.lha / dynamic / dynamic.lha / objsrc / dostest2.c < prev   
Encoding:
Text File  |  1991-04-29  |  375 b   |  22 lines

  1.  
  2. /*
  3.  *  DOSTEST2.C
  4.  *
  5.  *  test dos a bit more and a few other functions
  6.  */
  7.  
  8. void
  9. hyper_DosTest2()
  10. {
  11.     char buf[64];
  12.     int n;
  13.  
  14.     fhprintf(Output(), "Give me a line! ");
  15.     n = Read(Input(), buf, sizeof(buf)-1);
  16.     if (n > 0)
  17.     buf[n] = 0;
  18.     fhprintf(Output(), "You said: %s\n", buf);
  19.     fhprintf(Output(), "97 * %s = %d\n", buf, 97 * strtol(buf, (void *)0, 0));
  20. }
  21.  
  22.