Submission #646114

#TimeUsernameProblemLanguageResultExecution timeMemory
646114Hacv16Nadan (COCI18_nadan)C++17
50 / 50
1 ms212 KiB
#include<bits/stdc++.h> using namespace std; #define pb push_back #define sc second #define fr first #define all(x) x.begin(), x.end() #define sz(x) (ll) x.size() #define dbg(x) cerr << #x << ": [ " << x << " ]\n" typedef long long ll; typedef pair<int, int> pii; const int MAX = 2e6 + 15; const int INF = 0x3f3f3f3f; ll n, k; int main(){ ios_base::sync_with_stdio(false); cin.tie(NULL); cin >> n >> k; for(int i = 1; i <= k; n -= i, i++) cout << (i == k ? n : i) << '\n'; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...