제출 #1162598

#제출 시각아이디문제언어결과실행 시간메모리
1162598Isa2011Stove (JOI18_stove)C11
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h> #include <math.h> using namespace std; #define int long long #define fr first #define sc second #define pb push_back #define all(x) x.begin(), x.end() #define rall(x) x.rbegin(), x.rend() int mod = 1e9 + 7; const int N = 2 * 1e5; void solve() { int n,m; cin >> n >> m; vector<int> a(n); for (auto &it : a) cin >> it; sort(all(a)); vector<int> ans; for (int i = 1; i < n; i++) ans.pb(a[i] - a[i-1] + 1); sort(all(ans)); int h = n / m; int an = 0; for (int i = 0; i < h; i++) { an += ans[i]; } cout << an + h; } signed main() { ios::sync_with_stdio(false); cin.tie(nullptr); cout.tie(nullptr); //freopen("input.txt", "r", stdin); //freopen("output.txt", "w", stdout); // Isa2011 solve(); }

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

stove.c:1:10: fatal error: bits/stdc++.h: No such file or directory
    1 | #include <bits/stdc++.h>
      |          ^~~~~~~~~~~~~~~
compilation terminated.