Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please use C++ 2. CoLoRaDo Write a program that prints Co - Lo - Colo - Ra - Do - RaDo - CoLoRaDo in sequence
please use C++
2. CoLoRaDo Write a program that prints "Co - Lo - Colo - Ra - Do - RaDo - CoLoRaDo" in sequence 6 times. Here are some conditions you must satisfy: Generates a random integer number between (0.. 6). Based on the random number, the first word of the sequence is determined. For example, 0 --> Co, 2 --> Colo, 5--> RaDo, o It keeps printing the next word in circular sequence until it prints one before the first word in step one above. When the last word is printed, it goes to the next line and starts with the next word of the next word. (See an example below) Prints entire sequence 6 times. o Regardless of the starting word, the last line always should stop at "COLORaDo". O o Here is a sample output: Random number: 3 3 Ra - Do - RaDo- CoLoRaDo - Co - Lo - COLO Do - RaDo- CoLoRaDo - Co - Lo - COLO -Ra - - RaDo- CoLoRaDo - Co - Lo - COLO -Ra - Do CoLoRaDo - Co - Lo - Colo-Ra - Do - Rado Co - Lo - Colo - Ra - Do - RaDo - CoLoRaDo Lo - Colo - Ra - Do - RaDo - CoLoRaDoStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started