+ 4
SoloLearn doesnât support anything like that, you can only have input once at the beginning (each input separated by a new line) and then one output. Also only text output with the standard library.
Outside of SoloLearn:
Graphics engines will do this for you for games.
Without that:
You could get user input, or included some kind of timer:
#include <ctime>
or
#include <chrono>
Chrono works in microseconds, milliseconds, seconds, and maybe some others, but it probably creates more lag.
Ctime works in milliseconds only, but will create less lag. Iâd only use chrono if you need to be very accurate.