Question: Define enumeration type Paint that has the exact values [red, blue, yellow, green, orange, purple] Write function paintType that takes an argument of type Paint.

 Define enumeration type Paint that has the exact values [red, blue,

Define enumeration type Paint that has the exact values [red, blue, yellow, green, orange, purple] Write function paintType that takes an argument of type Paint. The function will test the argument and print out "primary color" if the color is red, blue, or yellow, and will print out "mixed color" otherwise Your selection structure should use a relational expression Your main function will prompt the user for a number and convert the number to a enumeration type Paint value 0-red 2-yellow 3-green 4-orange purple Your output should look like this one: Enter any of the following colors (0-red, 1-blue, 2-yellow, 3-green, 4-orange, 5 purple) 4 The color you entered is a mixed color! Enter any of the following colors (0-red, blue, 2=yellow, 3=green, 4-orange, 5-purple): 20 The color you entered is an incorrect option! Enter any of the following colors (0 red, 1=blue, 2=yellow, 3=green, 4-orange, 5-purple)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!