First of all I would like to Welcome you to this community of programmers.
Here is the code to do what you need
int CWordsDlg::GetRandomNumer(int high,int low)
struct tm SeedDate;
SeedTime = time(0);
SeedDate = *localtime(&SeedTime);
int FinalSeed = (int)SeedTime + SeedDate.tm_mday + (SeedDate.tm_mon+1) + (SeedDate.tm_year+1900);
srand((unsigned int) FinalSeed);
int Interval = high - low + 1;
int RandomOffset = rand() % Interval;
int RandomNumber = low + RandomOffset;
Its a fairly simple function which needs any explanation but then also if you need any just put a post here.