#include #include #include #include #include using namespace std;int main(){ ios::sync_with_stdio(false); cin.tie(nullptr); int N; cin >> N; int result = 0; vector arr(N); for (int i = 0; i > arr[i]; } sort(arr.begin(), arr.end()); result = arr[0]; for (int i = 1; i 문제분석사람들이 인출하는 데 걸리는 시간 Pi를 오름차순으로 정렬한 후,앞선 사람이 오래 걸릴수록 뒤 사람들은 더 많은 대기 시간을 더하게 되므로 , 걸리는 시간이 짦은 사람부터먼저 인출하는것이 총 대기시간을 최소화 한다. 1에서 5..