Exam 9: Records Structs
Exam 1: An Overview of Computers and Programming Languages50 Questions
Exam 2: Basic Elements of C50 Questions
Exam 3: Inputoutput50 Questions
Exam 4: Control Structures I Selection50 Questions
Exam 5: Control Structures II Repetition50 Questions
Exam 6: User-Defined Functions50 Questions
Exam 7: User-Defined Simple Data Types, Namespaces, and the String Type50 Questions
Exam 8: Arrays and Strings50 Questions
Exam 9: Records Structs50 Questions
Exam 10: Classes and Data Abstraction49 Questions
Exam 11: Inheritance and Composition50 Questions
Exam 12: Pointers, Classes, Virtual Functions, and Abstract Classes50 Questions
Exam 13: Overloading and Templates50 Questions
Exam 14: Exception Handling50 Questions
Exam 15: Recursion50 Questions
Exam 16: Searching, Sorting and the Vector Type50 Questions
Exam 17: Linked Lists50 Questions
Exam 18: Stacks and Queues50 Questions
Select questions type
struct newStudent
{
string firstName;
string lastName;
string courseGrade;
int testScore;
int programmingScore;
};
int score;
-Consider the accompanying struct definition. The statement that assigns the average of testScore and programmingScore to score is ____________________.
(Short Answer)
4.9/5
(26)
Typically, in a program, a struct is defined ____ in the program.
(Multiple Choice)
4.9/5
(27)
Which of the following struct definitions is correct in C++?
(Multiple Choice)
4.9/5
(43)
struct newStudent
{
string firstName;
string lastName;
string courseGrade;
int testScore;
int programmingScore;
};
int score;
-Consider the accompanying struct definition in Figure 1. The statement that initializes the member testScore to 95 is ____________________.
(Short Answer)
4.9/5
(36)
Consider the following statements: struct supplierType
{
string name;
int supplierID;
};
struct applianceType
{
supplierType supplier;
string modelNo;
double cost;
};
applianceType applianceList[25];
Which of the following statements correctly initializes the cost of each appliance to 0?
(Multiple Choice)
4.7/5
(30)
The contents of a struct variable must be written one member at a time.
(True/False)
4.8/5
(37)
The following statement defines a struct houseType with a total of ____________________ member(s).
struct houseType
{
string style;
int numOfBedrooms;
int numOfBathrooms;
int numOfCarsGarage;
int yearBuilt;
};
(Short Answer)
4.8/5
(30)
Showing 41 - 50 of 50
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)