Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int *zamien(int* tab, int ile)
- {
- int *tab2;
- for (int j = ile - 1; j >= 0; j--)
- {
- for (int k = 0; k <ile; k++)
- {
- tab[j] = tab2[k];
- }
- }
- return tab2;
- }
- int main()
- {
- int tab[100];
- int ileLiczb;
- cout << "Podaj ilosc liczb: " << endl;
- cin >> ileLiczb;
- cout << "Podaj liczby do przestawienia: " << endl;
- for (int i = 0; i < ileLiczb; i++)
- {
- cin >> tab[i];
- }
- cout <<zamien( tab, ileLiczb) << endl;
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement