CSLO1.1-1.5PRACTICE TESTIS220 COMPUTER PROGRAMMING
SLO 1.3 Explain three types of basic instructions- input, process output (C1.3 and C2.2)
MULTIPLE CHOICE:
Instructions: Identify the letter of the choice that best completes the statement or answers the question
- cin > unit_credit;
- is a program
- is an input statement
- is an output statement
- is a variable declaration
Answer:
- What does the following line of code display to the screen?
cout < “This is the basic\n programming book\n”;
- Nothing
- This is the basicn programming book
- This is the basic
- This is the basic
programming book
Answer:
- What does the following code print to the screen?
cout < “kasehlelie”;
- KASEHLELIE
- Kasehlelie
- kasehlelie
- Nothing
Answer:
- Which of the following lines correctly reads a value from the keyboard and stores it in the variable named myFloat?
- cin > myFloat > endl;
- cin > > myFloat;
- cin < myFloat;
- cin > "myFloat";
Answer:
SLO1.4 Identify programming tools-flowcharts, pseudocode, hierarchy chart and documentation basics (VB.Net file)
MULTIPLE CHOICE:
Instructions: Identify the letter of the choice that best completes the statement or answers the question
- Pseudocode is
- the incorrect results of a computer program.
- data that have been encoded for security.
- a program that doesn't work.
- the obscure language computer personnel use when speaking.
- a description of an algorithm similar to a computer language.
Answer:
- Which of the following types of charts shows only the relationships between general program tasks without showing specific modules or directions for data flow?
a)top-down chart
b)flowchart
c)both A and B
d)neither A nor B
Answer:
- If you are writing a program that needs to repeat a series of calculations, what programming structure should you use to repeat the calculations?
a)sequence structure
b)decision/control structure
c)looping/repeatiition structure
d)unconditional branching
Answer:
- "Desk-checking" refers to
a)the continual problem programmers have with losing things.
b)timing a program to see how fast it completes its tasks.
c)testing an algorithm at the flowchart stage using several different kinds of data.
d)having a fellow programmer read your pseudocode to be sure it is understandable.
Answer:
- A graphical depiction of the logical steps to carry out a task and show how the steps relate to each other is called a(n)
a)flowchart.
b)pseudocode.
c)algorithms.
d)hierarchy chart.
Answer:
SLO 1.5 Identify and describe the purpose of literals, variables, operators, and functions(C2.1-5, and C4)
MULTIPLE CHOICE:
Instructions: Identify the letter of the choice that best completes the statement or answers the question
- Which of the following is a valid identifier?
- 3-com
- 3com
- three_com
- 3_com
- dollar$
ANSWER:
- Which of the following is not a valid identifier?
- myInt
- return
- myInteger
- total3
ANSWER:
- What is the value of x after the following statements?
int x;
x = 15 %4;
- 3
- 4
- 15
- 3.75
ANSWER:
- What is the value of x after the following statements?
int x, y, z;
y = 10;
z = 3;
x = y + z * 3;
- Garbage
- 60
- 30
- 33
ANSWER:
- What is the value of x after the following statements?
int x;
x = x + 30;
- 0
- 30
- 33
- garbage
ANSWER:
CIS ProgramBusiness Division COM-FSM National Campus
1