Problem: 1701. 平均等待时间对每个顾客拿到上一个顾客的结束时间计算出当前顾客的结束时间计算等待时间累加即可的耗时100Codeclass Solution { public: double averageWaitingTime(vectorvectorint customers) { int n customers.size(), now customers[0][0]; int need customers[0][1], a, c; int end now need; long long wait need; for(int i 1; i n; i) { now end; a customers[i][0]; if(now a) now a; need customers[i][1]; end now need; wait end - a; } return wait / (double)n; } };