Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <time.h>
- #include <cstdlib>
- using namespace std;
- void tablica (int tab[],int a)
- {
- for (int i=0; i<a; i++)
- {
- tab[i]=1+rand()%(50);
- cout << tab[i] << endl;
- }
- }
- int main()
- {
- srand(time(NULL));
- int tab[10];
- tablica(tab,10);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment