Advertisement
laith-0093

C++

Jan 16th, 2020
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. #include <iostream.h>
  2. #include <conio.h>
  3. void main ()
  4. {
  5. char L;
  6. int M;
  7. L: cout << "\n\nEnter a character: ";
  8. cin >> L;
  9. cout << "Enter number of times to repeat it: " ;
  10. cin >> M;
  11. for (int j=0 ; j < M; j++)
  12. cout << L;
  13. goto L;
  14. getch();
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement