subject

In this exercise you will expand your timeInput. cpp, which only dealswith lecture times, so that you can have more information about each lecture, and print a schedule to the student. More specifically, you should keep your Timestructure from timeInput. cppand create a new Coursestructure consistedof the following variables:. 1. name, type string, which stores the name of the course 2. credits, type int, which stores the number of credits for the course 3. majorRequirement, type bool, whfch tells if the course is a requirement for your major 4. avgGrade, type double, which gives the average grade (in percentage) that past students received in the course 5. days, type string, which stores the days that lectures are held 6. startTime, type Time (from exercise 1), which is the start time of the lecture 7. endTime, type Time (from exercise 1), which is the end time of the lecture Your program should read the course information from a text file called "in. txt". This file should contain the following pieces of information on the lines specified below: Line 1: Course number: How many courses the user wants to sign up for. Line 2: Name of the course Line 3: Credits Line 4: Is the course a major requirement? (1-yes, 0-no) Line 5: Average grade for the course Line 6: Lecture days Line 7: Start time of the lecture Line 8: End time of the lecture Line 9-15: Repeat same information for additional course, if it exists. In order to receive full credit for this part of the lab, you MUST create the two In order to read the avgGrade, you will need to convert from strings to floats. The Note: structures, Time and Course, consisted of the proper variables. function you can use to do so is atof, which takes in an array of characters as a parameter (again, NOT a string). To convert a string to an array of characters, use the function cstr().

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 11:00
in 2007, floridians died in alcohol-related collisions.a.  501b.  1,051c.  5,015d.  10,839
Answers: 1
question
Computers and Technology, 23.06.2019 22:30
You draw two cards from a standard deck of 52 cards, but before you draw the second card, you put the first one back and reshuffle the deck. (a) are the outcomes on the two cards independent? why?
Answers: 3
question
Computers and Technology, 24.06.2019 00:50
3. what is the output of the following statements? temporary object1; temporary object2("rectangle", 8.5, 5); temporary object3("circle", 6, 0); temporary object4("cylinder", 6, 3.5); cout < < fixed < < showpoint < < setprecision(2); object1.print(); object2.print(); object3.print(); object4.print(); object1.set("sphere", 4.5, 0); object1.print();
Answers: 1
question
Computers and Technology, 24.06.2019 14:00
Which computer tools allow you to communicate with coworkers, family,and friends
Answers: 1
You know the right answer?
In this exercise you will expand your timeInput. cpp, which only dealswith lecture times, so that yo...
Questions
question
Mathematics, 23.06.2021 19:40
question
Chemistry, 23.06.2021 19:40
question
Mathematics, 23.06.2021 19:40
question
Mathematics, 23.06.2021 19:40
question
Mathematics, 23.06.2021 19:40
Questions on the website: 13722361