7 time(chrono::high_resolution_clock::now())
12 return chrono::duration_cast
<chrono::milliseconds
>(chrono::high_resolution_clock::now() - this->time
).count();
17 this->time
= chrono::high_resolution_clock::now();
20 ostream
& operator<<(ostream
& os
, const Timer
& t
)
22 os
<< t
.ms() << " ms";