I need to write a program that reads in an Array of N numbers -say N is 10- and outputs 5 random permutations of these numbers (so for each permutation/shuffling the numbers have to be re-arranged in some random order).
I need to use an algorithm called shuffle(array, size) (INPUT: array of integers array, integer size. OUTPUT: reshuffled array) and an algorithm RandomNumber(limit) (INPUT integer limit and OUTPUT a random integer between 0 and limit (exclusive)).
I know I need to use the rand()function to implement randNumber(int). I also know I need to use srand and the time library.
Can anyone please help me getting this started?
Thanks a lot!