Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main(){
- int x, b, a;
- cout << "Enter a numbers of B: ";
- cin >> b;
- cout << "Enter a numbers of A: ";
- cin >> a;
- cout << "\n";
- for(int i = 1; i <= b; b++){
- cout << "B";
- for(int i = 1; i <= a; a++){
- cout << "A";
- }
- cout << "\n\nEnter another? [1] YES [2] NO: ";
- cin >> x;
- if(x == 1){
- system("cls");
- cout << "\n";
- return main();
- }
- if(x == 2 || x > 2){
- system("pause");
- }
- cout << "Program Ends, Happy Programming!!!";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement