home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 1320 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.3 KB  |  43 lines

  1. Path: pegasus.montclair.edu!hubey
  2. From: hubey@pegasus.montclair.edu (H. M. Hubey)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: SAS/Lattice C question
  5. Date: 12 Jan 1996 21:41:53 -0500
  6. Organization: Montclair State University
  7. Message-ID: <hubey.821500755@pegasus.montclair.edu>
  8. References: <4d17sv$146$1@mhadg.production.compuserve.com>
  9. NNTP-Posting-Host: pegasus.montclair.edu
  10. X-Newsreader: NN version 6.5.0 #68 (NOV)
  11.  
  12.  
  13.  
  14. Hello
  15.  
  16. I had bought the Lattice C commpiler years ago but never
  17. got a chance to program. I tried a simple pgm from Jamsa's
  18. 1001 tips (shown below), and the compiler gives an error
  19. message. It's asking for a DEFINE value for stub xxxx.
  20. I don't understand what it could be asking for. There doesn't
  21. seem to be any functions except for those in stdio.h.
  22.  
  23. The little program is show below:
  24.  
  25. -------------------------------------------------------------------
  26. #include <stdio.h>
  27.  
  28. float average_value(int a, int b, int c)
  29.  {
  30.    return ((a + b + c) / 3.0);
  31.  }
  32.          
  33. void main(void)
  34.  {
  35.    printf("The average of 100, 133, and 155 is %f\n",
  36.      average_value(100, 133, 155));
  37.  }
  38.  
  39. -----------------------------------------------------------------
  40. -- 
  41. Those who speak don't know.               Those who know won't speak.
  42. http://www.smns.montclair.edu/~hubey      hubey@pegasus.montclair.edu
  43.