Académique Documents
Professionnel Documents
Culture Documents
Purchase here
http://devrycourse.com/cis%20170c/cis-170c-finalexam
Product Description
CIS 170C Final Exam Programming With Lab DeVry
(TCO 1) Which of the following statement about IDE is true? (Points : 4)
IDE only allows programmers to editing their code
(TCO 2) What does the symbol << represent in C++ programming? (Points : 4)
Bout
Bin
Cin
Count
Curly braces
Parentheses
Quotes
(TCO 2) To improve readability and maintainability, you should declare _____ instead of using
literal values such as 3.14159. (Points : 4)
Variables
Functions
Classes
Constants
(TCO 3) What is the value of x after the following statement? float x; x = 3.0 / 4.0 + 3 + 2 / 5
(Points : 4)
1.75
3.75
5.75
4.15
(TCO 4) _____ is often used in the design of a program to describe the program processing.
(Points : 4)
Pseudocode
Algorithm
Program control
Data flow
Rectangle
Circle Diamond
(TCO 5) Which structure causes a statement or set of statements to execute repeatedly? (Points :
4)
Decision
Repetition
Sequence
(TCO 5) Which repetition structure is designed to have the code execute at least one time?
(Points : 4)
For loop
Do in a while loop
While loop
Do while loop
(TCO 5) The while loop has two important parts: an expression that is tested for a true or false
value, and _____. (Points : 4)
A statement or block that is repeated as long as the expression is true
An infinite loop
A pretest loop
A post-test loop
Detective
(TCO 7) Code written in a specific format to perform a single task or calculation is called a
_____. (Points : 4)
Function
Loop
Decision statement
Task
(TCO 8) Unless otherwise specified, C++ variables are automatically passed by _____. (Points :
4)
Parameter
Argument
Reference
Value
Void function
Stacked function
Declared stack
&
(TCO 8) The parameter of the following function is a(n) _____. char myFunction (int &x);
(Points : 4)
Action parameter
Illegal parameter
Value parameter
Reference parameter
(TCO 9) What type of menu first displays the main menu and then, based on the users selection,
displays a submenu?(Points : 4)
Single-level menu
Multiple-level menu
Step-level menu
Sublevel menu
(TCO 9) What is the method used to make sure that valid selections are processed? (Points : 4)
(TCO 9) What software entity contains both data and procedures (actions on the data)? (Points :
4)
Objects
Instances
Events
(TCO 10) To halt the execution of a program at a specific spot during debugging, you must use a
_____. (Points : 4)
Scope resolution operator
Step
Comment
Break point
(TCO 11) If n represents the size of an array, what would be the index of the last element in the
array? (Points : 4)
n-2
n-1
Cannot be determined
(TCO 11) When working with an array, the easiest way to traverse or visit all elements of the
array is to _____. (Points : 4)
Use a loop statement
Do a binary search
(TCO 11) Given: myArray[3][4], what is the index for the first element (located in the first row
and first column)?
[1][1]
[0][1]
[1][0]
[0][0]
31 with 10
31 with 20
55 with 20
(TCO 12) What is the character automatically included at the end of an array of characters?
(Points : 4)
n
Binary order
Consecutive order
(TCO 13) Sometimes, a project will need to save data inputted by the user so it can be used
again. This data stored will later be accessed from a _____. (Points : 4)
Program file
Project file
Data file
User file
(TCO 13) Once you finish using a file, you should _____. (Points : 4)
Append it
Exit it
Output it
(TCO 13) Compare and contrast the mode operators ios::in, ios::app, and ios::out. Provide a C++
code segment that illustrates the use of these mode operators. (Points : 20)
(TCO 9) Explain which is more appropriate for writing a menu program: a switch case or if-else
statements. Provide a snippet of code to support your position. (Points : 15)
(TCO 11) Explain how a linear search is conducted to find a particular data value in an array.
Provide a C++ program segment to illustrate your answer. (Points : 15)
(TCO 7) Explain the difference between an argument and a parameter. Use a C++ program
segment to illustrate your answer.(Points : 15)
(TCO 5) Using a loop, write a program that adds and displays the total of all even integers from
1 to 10. (Points : 15)
(TCO 4) What is the advantage of using the conditional operator? (Points : 15)
(TCO 3) Explain the naming rules for creating variables and then provide three examples using
the data types int, double, and char and assign values to them. (Points : 15)