제출 #603130

#제출 시각아이디문제언어결과실행 시간메모리
603130Jarif_Rahman카니발 티켓 (IOI20_tickets)C++17
11 / 100
1 ms596 KiB
#include "tickets.h" #include <bits/stdc++.h> #define pb push_back #define f first #define sc second using namespace std; typedef long long int ll; typedef string str; ll find_maximum(int k, vector<vector<int>> v){ int n = v.size(), m = v[0].size(); vector<vector<int>> rt(n, {0}); allocate_tickets(rt); ll ans = 0; sort(v.begin(), v.end()); for(int i = 0; i < n/2; i++) ans-=v[i][0]; for(int i = n/2; i < n; i++) ans+=v[i][0]; return ans; }

컴파일 시 표준 에러 (stderr) 메시지

tickets.cpp: In function 'll find_maximum(int, std::vector<std::vector<int> >)':
tickets.cpp:11:23: warning: unused variable 'm' [-Wunused-variable]
   11 |     int n = v.size(), m = v[0].size();
      |                       ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...