Program Design
Question Description
i need some help with this homework for programing design
Write a program to randomize an array of digits 0 to 9, for instance, 2 3 1 9 8 4 7 5 6 0. Therandom positions of the 10 digits will be generated by randomly swapping two digits in the array10 times.The program will start with an array of size 10 of elements 0 1 2 3 4 5 6 7 8 9, then use rand()function to generate 2 random positions in the range of 0 to 9 as the index of the digits andswap the two digits. For example, given the array 0 1 2 3 4 5 6 7 8 9, if the two random positionsare 2 and 8, then the resulting array of the swapping will be 0 1 8 3 4 5 6 2 9. The program willdo 10 times of generating 2 random positions and swapping.
i attached a file that descripe the hole thing
Have a similar assignment? "Place an order for your assignment and have exceptional work written by our team of experts, guaranteeing you A results."