Advertisement
a53

ElimP

a53
Jan 10th, 2019
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. #include <iostream>
  2. #include <cstring>
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. int p;
  8. char s[256];
  9. cin>>p;
  10. cin.get();
  11. cin.get(s,256);
  12. int L=strlen(s);
  13. for(int i=0;i<L-p+1;++i)
  14. {
  15. for(int j=0;i>0&&j<i;++j)
  16. cout<<s[j];
  17. for(int j=i+p;j<L;++j)
  18. cout<<s[j];
  19. cout<<'\n';
  20. }
  21. return 0;
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement