Question: Use the array: string messages[5]={ Be safe, Study more,Help others, Go to movie, Go to Los Vegas}; Generate a random number between 0 and 4
![Use the array: string messages[5]={ "Be safe", "Study more","Help others, Go](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f3bc4fb2dbb_48766f3bc4f49fa7.jpg)
Use the array: string messages[5]={ "Be safe", "Study more","Help others, Go to movie", "Go to Los Vegas}; Generate a random number between 0 and 4 to display one of the above messages. Which of the messages displayed more than others? Sample Input Be safe CONTINUE(y)? y Help others CONTINUE(y)? y Be safe CONTINUE(y)? n The message "Be safe" displayed more often
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
