Title: DEVRY CIS 115 Final Exam 2
1DEVRY CIS 115 Final Exam 2
- Check this A tutorial guideline at
-
- http//www.assignmentcloud.com/cis-115/cis-115-fin
al-exam-2 - For more classes visit
- http//www.assignmentcloud.com
- CIS 115 Final Exam 2
- 1. What is the first step in software
development? - 2. What are named locations in a computers
memory holding information required by a program? - 3. What symbol in a flowchart would be used by a
developer to represent the beginning or ending
point? - 4. ) Set name BSCIS is a process. What data
type would you expect the variable, name, to
have? - 5. (You are using dollar amounts in an algorithm.
What data type would you assign? - 6. What tool is used by developers to design
logic using specific shapes/symbols? - 7. When a program evaluates mathematical
expression, which of the following operators (or
mathematical operations) takes precedence? - 8. (Which one of the following is a valid
assignment statement in a program? - 9. (Evaluate (2 3) 3.
- 10. (TCO 2) Review the partial pseudocode below.
What is the correct math expression to complete
the algorithm and total sales for both regions?
210. (TCO 2) Review the partial pseudocode below.
What is the correct math expression to complete
the algorithm and total sales for both
regions?Prompt Enter total sales for region 1
Input region1Prompt Enter total sales for
region 2 Input region2Set _____Display
total sales total (Points 4)11. (TCO 3
4) Review the pseudocode below. What will be
displayed when this algorithm executes?SetIf
((x gt 10) AND (x lt 20))""gtDisplay the IF
path executesElseDisplay the ELSE path
executesEndIf (Points 4)12. (TCO 3 4) What
value gets displayed for the variable X?SetSetS
etIf (B gt 15) AND (() OR (C lt
15))""gtSetElseSetEndIfDisplay X (Points
4)
313. (TCO 3 4) In the following pseudocode, what
raise will an employee in Department 6
receive?If department lt 2""gtSetElseIf
department lt 6""gtSetElseSetEndIfEndIf
(Points 4)14. (TCO 3 4) Which of the
selection structures determine whether the user
enters a number outside a range of 5 and 15?
(Points 4)15. (TCO 3 4) What value gets
displayed for the variable Z?SetSetSetIf
((balance ltgt 800) OR (stateCodeltgt 6) OR
(creditCodeltgt 7) thenSetElseSetEndIfDisplay
Z (Points 4)1. (TCO 5) The statements executed
within a loop are known collectively as the
_____. (Points 4)2. (TCO 5) Which of the
following statements is false? (Points
4)3. (TCO 5) A DO loop is considered what type
of loop? (Points 4)4. (TCO 5) What happens
when the loop control variable is not changed?
(Points 4)
45. (TCO 5) How many times will the following loop
be executed?SetDOWHILE numltgtDisplay numSet
1ENDO (Points 4)6. (TCO 7) What is another
name for an arrays index? (Points 4)7. (TCO
7) Suppose you have an array named number,and
two of its elements are number(1) and number(4).
You know that _____. (Points 4)8. (TCO 7)
Which one of the following correctly declares a
zero-based array of four integers? (Points
4)9. (TCO 7) When processing the elements of an
array, what control structure is used to move
through each element within the array? (Points
4)10. (TCO 7) A zero-based array named sales has
been declared and loaded with the values 100,
1100, 3400, 5550, 3000, 22300, and 1200. What
value will be stored in the array
element sales(1)? (Points 4)11. (TCO 6) A file
contains _____. (Points 4)12. (TCO 6) What is
automatically placed at the bottom of a file when
the file is closed? (Points 4)13. (TCO 8)
Menu-driven programs need to give the user the
option to _____. (Points 4)14. (TCO 9) What
type of error occurs when a program will not
execute because the rules of the language have
been violated? (Points 4)15. (TCO 2) The first
module is usually considered to be called the
_____ module. (Points 4)1. (TCO 10) A retail
store is having a customer appreciation sale.
Depending on the total dollars purchased, the
customer could receive a discount on his or her
total purchases. You are to develop pseudocode
that will obtain the total dollars purchased from
the user, determine the discount percentage, and
display the total amount due. When the purchases
are more than 100, the discount is 10. When the
purchases are 100 or less, the discount is 5.
(Points 10)2. (TCO 10) A small business in
your neighborhood would like an application
developed that determines the average dollar
amount spent for every three purchases. The user
will enter three different purchase amounts. You
need to display the average to your client.
Complete the pseudocode to design your logic.
(Points 10)3. (TCO 9 10) There is a logic
error in the following pseudocode. The loop needs
to execute four times. What statement(s) would
you need to add or change to correct the logic?
Be sure to explain why you are adding or changing
the statements.
5- SetREPEATSet 1UNTIL total ltgtEndWhileDisplay
total (Points 10) - 4. (TCO 4 10) Complete the pseudocode by
rewriting the algorithm. The design is
determining the correct sales tax depending on
the county identifying code. Counties with a
number less than 10 have a 6 sales tax. The
1125 codes have a sales tax of 7. Codes above
25 have a sales tax of 8. The code is entered by
the user.BeginDeclare Real salesTaxDeclare
_____ countyCode_____ Enter the county code
_____ countyCodeIf _____ lt 10""gtSetElseIf
_____ AND _____ thenSetElse_____EndIf_____Di
splay the sales tax is _____End (Points
10)
6BeginDeclare String color1Declare String
color2Declare String control1Declare String
control2_____ Enter first primary color
Input _____Prompt Enter the second primary
color Input _____Set control1 nDOWHILE
control1 nIf (color1 ltgt yellow) _____
(color1 ltgt red) _____ (color1 ltgt blue)
thenPrompt first primary color is
invalidInput _____ElseSet control1
yENDOSet control2 nDOWHILE control2
nIf (color2 ltgt yellow) _____ (color2 ltgt
red) _____ (color2 ltgt blue) thenPrompt
second primary color is invalidInput
color2ElseSet control2 yENDOIf (color1
red) AND (_____) thenDisplay secondary color
is purpleEndIf