# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
839108 | Bula | Nadan (COCI18_nadan) | C++14 | 1 ms | 260 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pb push_back
#define all(x) x.begin(),x.end()
#define rall(x) x.rbegin(),x.rend()
#define ff first
#define sc second
#define int ll
const ll mod = 1e9 + 7, N = 1e5 + 1;
main(){
int k, n;
cin >> k >> n;
int sum = 0;
for(int i = 1; i <= n - 1; i++){
cout << i << endl;
sum += i;
}
cout << k - sum << endl;
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |