Put your name, Lab Exercise 10, and compiler and the operating system used in a comment at the top of your program. Email only your source code. Your source code should be sent as an attachment (with the name ex10.cpp). Use "Ex10" as the subject of your email submission
Write a program in which you generate 1000000 random numbers between 1 and 10. Store the number of occurrences of each random number in an array. Print out the array. Match this format exactly:
1 99854 2 99899 3 100022 4 100177 5 100055 6 99729 7 99602 8 100653 9 100269 10 99740 |
Do not declare a 1000000 element array. You only need a 10 element array for this problem. You can use a 11 element array if you want.