COMPETENCY CORRECT 100%
What is the purpose of a variable? - ANSWERa named item like x, used to hold a value.
How do you save a value to a variable? - ANSWERAn assignment statement assigns a
variable with a value. (x = 0)
What is a programming expression? - ANSWERA number, variable (x), or simple
calculation (numApples + 1).
What is an identifier? - ANSWERA name created for a variable or a function.
What constitutes a valid identifier? - ANSWERAn identifier must start with a letter and
be a sequence of letters, underscores, and digits.
What is a literal? - ANSWERany number, text, or other information that directly
represents a value.
What is an operator? - ANSWERa symbol that performs a built-in calculation. (+, -, *, /)
What precedence rules does programming use? - ANSWERPEMDAS
How does an integer differ from a float? - ANSWERIntegers are whole numbers and
used for counted values.
Floats allow the decimal point to appear anywhere in the number and are used for
values that are measured or fractions.
What happens if you divide two integers? - ANSWERyou will get an integer or the
answer will be cut short
what happens if you divide an integer and float? - ANSWERIt returns a float
What happens if you divide a nonzero floating point number by zero? - ANSWERIn
coral -infinity or infinity. Otherwise not a number.
How do you convert an item's type? - ANSWERBy using a type conversion.
What does the modulo operator do? - ANSWERevaluates to the remainder of the
division of two integer operands.
What is the difference in a variable and a constant? - ANSWERA variable can change
while a constant is a value that always stays the same.
, How does an array work? - ANSWERIt is a collection of data stored in an index
together.
What does index reference? - ANSWERThe location where values are stored in an
array.
What are the four phases of SDLC? - ANSWERanalysis, design, implementation,
testing
What activities takes place in each of the four phases? - ANSWERanalysis - defines
programs goals
design - defines how to build the program
implementation - writing the program
testing - checks that the program meets the goals
In which phase do you write code? - ANSWERimplementation
How does a waterfall approach differ from an agile approach? - ANSWERIn a waterfall
approach yo cannot go back to previous phases. In agile approach you can go back to
different phases.
What is UML? - ANSWERa modeling language that uses different types of diagrams to
visualize the structure and behavior of a program
Which UML diagrams are structural? - ANSWERclass diagram
Which UML diagrams are behavioral? - ANSWERActivity diagram, use case diagram,
sequence diagram
Which UML diagrams are activity? - ANSWERflowcharts
Which UML diagrams are used in the analysis phase? - ANSWERUse case diagram
Which UML diagrams are used in the design phase? - ANSWERclass diagram
Which UML diagrams are used in the implementation phase? - ANSWERActivity
Which UML diagrams are used in the testing phase? - ANSWERSequence diagram
What is a use case diagram used for? - ANSWERvisually models how a user interacts
with a program.
What is a class diagram used for? - ANSWERvisually models the classes of a computer
program.