|
|
вернуться в форумMy Code: #include <bits/stdc++.h> using namespace std; int main() { //freopen("in.txt","r", stdin); unsigned long long int n,k,x,j; cin >> n; for(int i=1; i<=n; i++) { cin >> k; x=1; j=0; while(j<k) { j+=x; if(j<k) x++; } x--; if(j-k < x) cout << 0 << " "; else cout << 1 << " "; } cout << endl; return 0; } Edited by author 26.04.2016 00:41 |
|
|