自己写一个:小弟献丑了:void settime(int sleeptime){time_t start_time;time_t end_time;do{time(end_time);}while(end_time-start_time>sleeptime);cout<<"done\n";}我忘了time(&start_time);DO 前