Gửi bài giải
Điểm:
10,00 (OI)
Giới hạn thời gian:
1.0s
Giới hạn bộ nhớ:
977M
Input:
stdin
Output:
stdout
Tác giả:
Người đăng:
Dạng bài
Ngôn ngữ cho phép
C++, PyPy, Python
Bài tập Lập trình sáng tạo
Bình luận
include<bits/stdc++.h>
using namespace std;
define ll long long
define ld long double
define fo(i,a,b) for(int i = a; i <= b; ++i)
define of(i,b,a) for(int i = b; i >= a; --i)
const int MOD = 1e9+7; const int nmax = 1e6+5;
ll n, a[nmax];
void dequy(ll x) { for (int i = 1; i >= 0; i--) { a[x] = i; if (x == n) { for (int j = 1; j <= n; j++) cout << a[j]; cout << '\n'; } else dequy(x + 1); } }
int main() { iosbase::syncwith_stdio(0); cin.tie(0); cout.tie(0); cin >> n; dequy(1); }