Submission #313476

#TimeUsernameProblemLanguageResultExecution timeMemory
313476PixelCatNadan (COCI18_nadan)C++14
50 / 50
1 ms384 KiB
/* _____ __ __ /^--^\ | () )\ \/ / \____/ |_()_) |__| / \ _____ _ __ __ ____ _ ____ ____ _____ | || ()_)| |\ \/ /| ===|| |__ / (__` / () \|_ _| \__ __/ |_| |_|/_/\_\|____||____|\____)/__/\__\ |_| |^|^\ \^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^|^| | | |\ \| | | | | | | | | | | | | | | | | | | | | | | | | #####/ /################################################# | | |\/ | | | | | | | | | | | | | | | | | | | | | | | | | |_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_| | #include <Orz/i_am_noob.h> #include <Orz/balbit.h> #include <Orz/nathanlee726.h>*/ #include <bits/stdc++.h> using namespace std; using ll=long long; using ull=unsigned long long; using pii=pair<ll,ll>; #define int ll #define For(i,a,b) for(int i=a;i<=b;i++) #define Forr(i,a,b) for(int i=a;i>=b;i--) #define F first #define S second #define eb emplace_back #define all(x) x.begin(),x.end() #define sz(x) ((int)x.size()) #define mkp make_pair #define MOD (ll)(1e9+7) #define INF (1e18) #define EPS (1e-6) #ifdef LOCALMEOW #define debug(...) do{\ cerr << __PRETTY_FUNCTION__ << " - " << __LINE__ <<\ " : ("#__VA_ARGS__ << ") = ";\ _OUT(__VA_ARGS__);\ }while(0) template<typename T> void _OUT(T x) { cerr << x << "\n"; } template<typename T,typename...I> void _OUT(T x,I ...tail) { cerr << x << ", "; _OUT(tail...); } #else #define debug(...) #endif void INIT(){ ios::sync_with_stdio(false); cin.tie(0); } int gcd(int a,int b) { return b==0?a:gcd(b,a%b); } int lcm(int a,int b) { return a/gcd(a,b)*b; } int fpow(int b,int p){ int ans=1,now=b; while(p){ if(p&1) ans=ans*now%MOD; p/=2; now=now*now%MOD; } return ans; } int32_t main(){ INIT(); //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //I won't misunderstand the problem statement anymore. //code... int k,n; cin>>k>>n; For(i,1,n-1){ cout<<i<<"\n"; k-=i; } cout<<k<<"\n"; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...