I am trying to use the following code to simulate a simple text-loading animation:
for (int i = 0; i < 15; i ++)
{
system("cls");
cout<<disp;
disp += ".";
Sleep(100);
}
system("cls");
However, the screen keeps blinking when I’m doing this. Is there a better way I can do this?
Thanks.
It seems like this would do the same thing your code is trying to do: