Here's an easier & improved version for intensive use:
#include <chrono>
#include <thread>
using namespace std::chrono_literals;
using namespace this_thread;
sleep_for(255ms); // use ms for miliseconds, s for seconds, min for minutes and h for hours`
Sorry if I made any errors, I'm new to c++ programing.