Consider the following c++ enumerated data type. A. Declare a variable. B. Write a for loop to properly iterate through the entire ordered list to display all associated values, i.e., ALGEBRA would...



  1. Consider the following c++ enumerated data type.


    A. Declare a variable.
    B. Write a for loop to properly iterate through the entire ordered list to display all associated values, i.e., ALGEBRA would result in: cout < “algebra”=""><>










enumcourseType {ALGEBRA, BEGINNING_SPANISH, ASTRONOMY, GENERAL_CHEMISTRY, PHYSICS, LOGIC};


courseTypeMath = ALGEBRA;
courseTypeLang = BEGINNING_SPANISH;
courseTypeSc1 = ASTRONOMY;
courseTypeSc2 = GENERAL_CHEMISTRY;
courseTypeSc3 = PHYSICS;
courseTypeMath2 = LOGIC;


for (courseTypeMath = ALGEBRA; courseTypeMath2 <=logic; coursetypesc1="ASTRONOMY;" coursetypesc2=""><= general_chemistry;="" coursetypesc3=""><=>


enumcourseType {ALGEBRA, BEGINNING_SPANISH, ASTRONOMY, GENERAL_CHEMISTRY, PHYSICS, LOGIC};


courseTypeMath = ALGEBRA;
courseTypeLang = BEGINNING_SPANISH;
courseTypeSc1 = ASTRONOMY;
courseTypeSc2 = GENERAL_CHEMISTRY;
courseTypeSc3 = PHYSICS;
courseTypeMath2 = LOGIC;


for (courseTypeMath = ALGEBRA; courseTypeMath2 <=logic; coursetypesc1="ASTRONOMY;" coursetypesc2=""><= general_chemistry;="" coursetypesc3=""><=>





Jun 08, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here