Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <fstream>
- using namespace std;
- int x;
- void f(int x)
- {
- cout<<x<<" ";
- while(x<7)
- {
- f(x+1);
- x++;
- cout<<endl;
- }
- }
- int main()
- {cin>>x;
- f(x);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement