arturParchem

ćwiczeniedod 1 informatyka.wsip.pl

May 21st, 2020
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.22 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3. string codruga(string napis) {
  4. string pomoc;
  5. for(int i=0;i<napis.size();i+=2)
  6. {
  7.     pomoc=pomoc+napis[i];
  8. }
  9. return pomoc;
  10. }
  11. int main()
  12. {
  13.     cout<<codruga("aksamitka");
  14.     return 0;
  15. }
Add Comment
Please, Sign In to add comment