제출 #433273

#제출 시각아이디문제언어결과실행 시간메모리
433273tengiz05Jelly Flavours (IOI20_jelly)C++17
컴파일 에러
0 ms0 KiB
#include "jelly.h" #include <vector> int find_maximum_unique(int x, int y, std::vector<int> a, std::vector<int> b) { int n = a.size(); sort(a.begin(), a.end()); int ans = 0; for (int i = 0; i < n; i++) { if (x >= a[i]) { x -= a[i]; ans++; } } return ans; }

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

jelly.cpp: In function 'int find_maximum_unique(int, int, std::vector<int>, std::vector<int>)':
jelly.cpp:6:2: error: 'sort' was not declared in this scope; did you mean 'short'?
    6 |  sort(a.begin(), a.end());
      |  ^~~~
      |  short