제출 #352627

#제출 시각아이디문제언어결과실행 시간메모리
352627beksultan04카니발 티켓 (IOI20_tickets)C++14
0 / 100
1 ms364 KiB
#include "tickets.h" #ifndef EVAL #include "grader.cpp" #endif // EVAL #include <bits/stdc++.h> using namespace std; #define lol long long #define pii pair<int,int> #define OK puts("OK"); #define NO puts("NO"); #define YES puts("YES"); #define fr first #define sc second #define ret return #define scanl(a) scanf("%lld",&a); #define scanll(a,b) scanf("%lld %lld",&a, &b); #define scanlll(a,b,c) scanf("%lld %lld %lld",&a,&b,&c); #define scan1(a) scanf("%d",&a); #define scan2(a,b) scanf("%d %d",&a, &b); #define scan3(a,b,c) scanf("%d %d %d",&a,&b,&c); #define all(s) s.begin(),s.end() #define allr(s) s.rbegin(),s.rend() #define pb push_back #define sz(v) (int)v.size() #define endi puts(""); #define eps 1e-12 long long find_maximum(int k, vector<vector<int>> x) { int n = x.size(),sum=0; int m = x[0].size(),i; vector<vector<int>> answer; answer.resize(n); for (i = 0; i < n; i++) { sum += x[i][0]; answer[i].push_back(0); } sum /= n; int ans = 0; for (i=0;i<n;++i){ ans += abs(sum-x[i][0]); } allocate_tickets(answer); return ans; }

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

tickets.cpp: In function 'long long int find_maximum(int, std::vector<std::vector<int> >)':
tickets.cpp:29:6: warning: unused variable 'm' [-Wunused-variable]
   29 |  int m = x[0].size(),i;
      |      ^
#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...