Thread: C Headerfile problems

  1. #1

    C Headerfile problems

    I am trying to run a programm which asks arithmatic questions. I am getting an error "declaration terminated incorrectly" in the header file; here are the codes; Please let me know if you can find the prob. Thanxxxx

    * File: RandDef.h
    * Header file for RandDef.c, source file of definitions of
    * random number generating functions

    #ifndef RANDOM
    #define RANDOM

    #include <stdlib.h>
    #include <time.h>

    void SeedRand(void);
    float random_float(void);
    float random_float_range(float LowerBound, float UpperBound);

    int random(int UpperBound); (THIS IS WHERE IT SAYS INCORRECT DECLARATION) ?????????

    int random_range(int LowerBound, int UpperBound);


  2. #2
    Registered User
    Join Date
    Jan 2002
    I think random() is already defined in stdlib.h, try changing it's name.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. No clue how to make a code to solve problems!
    By ctnzn in forum C Programming
    Replies: 8
    Last Post: 10-16-2008, 02:59 AM
  2. C Pointers Problems
    By mhelal in forum C Programming
    Replies: 8
    Last Post: 01-10-2007, 06:35 AM
  3. String Manipulation problems -_-
    By Astra in forum C Programming
    Replies: 5
    Last Post: 12-13-2006, 05:48 PM
  4. contest problems on my site
    By DavidP in forum Contests Board
    Replies: 4
    Last Post: 01-10-2004, 09:19 PM
  5. DJGPP problems
    By stormswift in forum C Programming
    Replies: 2
    Last Post: 02-26-2002, 04:35 PM