why the result is always the same?
#include<iostream.h>
#include<conio.h>
#include<time.h>
#include<dos.h>
#include<stdlib.h>
int main()
{
int a,b,c;
clrscr();
a = 5; b = 5; c = 5;
for(int x=1; x<=24; x++)
{
gotoxy(5,x);
cout << "*";
gotoxy(70,x);
cout << "*";
delay(50);
}
clrscr();
do
{
for(int x=1; x<=24; x++)
{
gotoxy(5,x);
cout << "*";
gotoxy(70,x);
cout << "*";
}
gotoxy(a,5);
cout << "A";
gotoxy(b,10);
cout << "B";
gotoxy(c,15);
cout << "C";
a = a + rand()%5+1;
b = b + rand()%5+1;
c = c + rand()%5+1;
delay(50);
}
while(a<=70 || b<=70 || c<=70);
getch();
return 0;
}