wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

D278 Scripting and Programming quiz

Total questions: 87

Worksheet time: 44mins

Name
Class
Date
1.

A loop consisting of a loop variable initialization, a loop expression, and a loop variable update that typically describes iterating for a specific number of times.

a)

for loop

b)

Pseudocode

c)

Nested Loop

d)

parameter

2.

The progress of writing, compiling, and testing a small amount of code, then writing, compiling, and testing a small amount more (an incremental amount), and so on.

a)

structural diagrams

b)

Incremental development

c)

Modular development

d)

Implementation

3.

First step in the waterfall approach. Defines a program's goals.

a)

Analysis

b)

Design

c)

Implementation

4.

A function input specified in a function definition.

a)

parameter

b)

interpreter

c)

Argument

d)

Iteration

5.

A number with a fractional part, even if that fraction is 0.

a)

floating-point number

b)

Algorithm time efficiency

c)

function definition

d)

Floating-point literal

6.

Used to run a program's statements.

a)

Not a number

b)

Iteration

c)

Interpreter

d)

Class diagram

7.

The second step in the waterfall approach of SDLC. Defines specifics of a program.

a)

Analysis

b)

Design

c)

Implement

d)

Test

8.

Text (characters) within double quotes.

a)

Nested Loop

b)

String literal

c)

Binary number

d)

Run, execute

9.

A program performs computations on that data, such as adding two values like x + y.

a)

Program

b)

Comment

c)

Input

d)

Process

10.

Modeling language for software design that uses different types of diagrams to visualize the structure and behavior of programs.

a)

Universal Modeling Language

b)

Behavioral diagrams

c)

Incremental Development

d)

Modular development

11.

A graphical language for creating computer programs.

a)

Characters

b)

Flowchart

c)

Function

d)

Boolean

12.

A program can be built by doing small amounts of each SDLC phase in sequence, then repeating. What is this approach called?

a)

Sequence diagram

b)

Agile or spiral approach

c)

Systems development life cycle (SDLC)

d)

Loop

13.

A function may return one value and does so by assigning a return variable with the return value. What is this return variable known as?

a)

Return statement

b)

Return variable

c)

Type conversion

d)

Nested branches

14.

Which concept supports decomposing a program into objects?

a)

Behavioral diagrams

b)

Not a number

c)

Assignment statement

d)

Object-oriented language

15.

What is each element's location number in an array called?

a)

Iteration

b)

Index

c)

Byte

d)

Boolean

16.

What type of loop that repeatedly executes the loop body while the loop's expression evaluates to true?

a)

While loop

b)

Characters

c)

Arguments

d)

Function

17.

Any function input values that appear within (), and are separated by commas if more than one.

a)

Arguments

b)

Argument

c)

Characters

d)

RandomNumber()

18.

Engineers have reduced switch sizes by half about every 2 years.

a)

function call

b)

Moore's Law

c)

Expression

d)

Type conversion

19.

Can be a number, a variable name (numApples), or a simple calculation like (numApples + 1).

a)
Expression
b)

Operator

c)

Iteration

d)

While loop

20.

Dividing a nonzero floating-point number by zero.

a)

object-oriented language

b)

structural diagrams

c)

Infinity or -Infinity

d)

function definition

21.

American Standard Code for Information Interchange. Code that is the numerical representation of a character. Ex: Z would be stored in a computer as 01011010.

a)

if-else

b)

sequence diagram

c)

Design

d)

ASCII

22.

A list of statements, each statement carrying out some action and executing one at a time.

a)

algorithm

b)

Program

c)

Function

d)

library

23.

Statement that returns the specified value and immediately exits the function.

a)

return statement

b)

Precedence rules

c)

Use Case Diagram

d)

Implementation

24.

An invocation of a function's name, causing the function's statements to execute.

a)

Function

b)

Precedence rules

c)

function call

d)

modulo operator

25.

Any letter (a-z, A-Z), digit (0-9), or symbol (+, -, *, etc.).

a)

Not a number

b)

Expression

c)

Characters

d)

Argument

26.

A single 0 or 1.

a)

Operator

b)

integer

c)

bit

d)

Loop

27.

A decision and its two branches. If the decision's expression is true then the first branch executes, ELSE the second branch executes.

a)

Function

b)

Use Case

c)

If-Else

d)

for loop

28.

A program construct that repeatedly executes the loop's statements (known as loop body).

a)

Loop

b)

Array

c)

Output

d)

comment

29.

Interaction between software components and order of events

a)

return statement

b)

activity diagram

c)

sequence diagram

d)

ASCII

30.

Type that has just two values: true or false.

a)

Boolean

b)

output

c)

nested loop

d)

comment

31.

Used by programs to refer to data. It is a named item, used to hold a value.

a)

Epsilon

b)

Argument

c)

comment

d)

variable

32.

A conversion of one data type to another, such as an integer to a float.

a)

Implementation

b)

Type conversion

c)

function definition

d)

Precedence rules

33.

Checks whether two operands' values are the same (==) or different(!=).

a)

return statement

b)

Implementation

c)

logical operator

d)

Equality operator

34.

A program written in a compiled language is first converted by a tool (compiler) into machine code, which can run on a particular machine. E.g., C, C++, and Java.

a)

Incremental development

b)

compiled language

c)

Use Case Diagram

d)

Sentinel value

35.

A program gets data, perhaps from a file, keyboard, touchscreen, network, etc.

a)

input

b)

operator

c)

branch

d)

process

36.

Treats operands as being true or false, and evaluates to true or false.

a)

Use Case Diagram

b)

logical operator

c)

Divide-by-zero error

d)

activity diagram

37.

A symbol that performs a built-in calculation, like the '+' which performs addition.

a)

modulo operator

b)

Characters

c)

Operator

d)

Use Case

38.

A word that is part of the language, like integer, Get or Put. These words cannot be used as an identifier.

a)

Universal Modeling Language

b)

floating-point number

c)

Reserved word (or keyword)

d)

Interpreted Language

39.

Loop that first executes the loop body's statements, then checks the loop condition.

a)

do-while loop

b)

Use Case Diagram

c)

Expression

d)

while loop

40.

Refers to the decimal point being able to appear anywhere ('float') in the number. Ex: 9%, 0.0006.

a)

Equality operator

b)

Sentinel value

c)

floating-point number

d)

relational operator

41.

Carrying out the SDLC phases in sequence.

a)

Function definition

b)

Lower camel case

c)

Waterfall Approach

d)

Structural diagrams

42.

Consists of the new function's name and block of statements.

a)

Function definition

b)

Floating-point number

c)

Structural diagrams

d)

Divide-by-zero error

43.

A sequence of statements only executed under a certain condition.

a)

Algorithm

b)

Argument

c)

Variable

d)

Branch

44.

Special value indicating the end of a list, such as a list of positive integers ending with 0 — function call.

a)

True

b)

False

45.

UML diagrams used to design dynamic elements of a program — behavioral diagram.

a)

True

b)

False

46.

A value provided to a function's parameter during a function call. — Characters.

a)

True

b)

False

47.

Behavioral diagram used to visually model how a user interacts with a software program. — Type conversion.

a)

True

b)

False

48.

UML diagrams used to design static elements of a program — structural diagram.

a)

True

b)

False

49.

A named list of statement — function.

a)

True

b)

False

50.

Sequence of steps that solves a program, generating correct output for any valid input values. — library.

a)

True

b)

False

51.

A named value item that holds a value that cannot change. — Characters.

a)

True

b)

False

52.

A name created by a programmer for an item like a variable or function. Must be a sequence of letters, underscores, and digits or start with a letter or underscore. They are case sensitive. — Identifier.

a)

True

b)

False

53.

A process in which a programmer writes and tests a few statements, then writes and tests a small amount more. — compiled language.

a)

True

b)

False

54.

Declares a new variable, specifying the variable's name and type. — variable declaration.

a)

True

b)

False

55.

Capitalize each word except the first, as in numApples. — Lower camel case.

a)

True

b)

False

56.

A flowchart of an activity (loop, function, etc.) within the program — activity diagram.

a)

True

b)

False

57.

Describes a singular goal of one user and briefly outlines how they will accomplish the goal — Pseudocode.

a)

True

b)

False

58.

Text that resembles a program in a real programming language but is simplified to aid human understanding is a while loop.

a)

True

b)

False

59.

Variable type that can hold whole numbers is an integer.

a)

True

b)

False

60.

Each item in an array is an index.

a)

True

b)

False

61.

Occurs at runtime if a divisor is 0, causing a program to terminate is a divide by zero error.

a)

True

b)

False

62.

19. Modulo operator evaluates to the remainder of the division of two integer operands. Ex: 23 % 10 is 3.

a)

True

b)

False

63.

A floating point number checks how one operand's value relates to another. For example, x > y.

a)

True

b)

False

64.

A special variable having one name, but storing a list of data items, with each item being directly accessible is an Array.

a)

True

b)

False

65.

The difference threshold indicating that floating-point numbers are equal is an Expression.

a)

True

b)

False

66.

A program puts that data somewhere, such as to a file, screen, network, etc. is an input.

a)

True

b)

False

67.

A list of statements executed by invoking the function's name, with such invoking know as a function call is a Program.

a)

True

b)

False

68.

Text a programmer adds to a program, to be read by humans (other programmers), but ignored by the program when executing, is called a comment.

a)

True

b)

False

69.

An expression is evaluated using the order of standard mathematics, which is known as Precedence rules.

a)

True

b)

False

70.

A language that is run one statement at a time by another program called an interpreter, such as Python, JavaScript, C#, is called a compiled language.

a)

True

b)

False

71.

A set of style guidelines defined by a company, team, teacher, etc., for naming variables is called a floating-point number.

a)

True

b)

False

72.

The process of dividing a program into separate modules that can be developed and tested separately and then integrated into a single program is known as Incremental development.

a)

True

b)

False

73.

Analysis Phase, Design Phase, Implementation phase, testing phase are stages of the Systems development life cycle (SDLC).

a)

True

b)

False

74.

A loop that appears in the body of another loop in Pseudocode is called a Nested loop.

a)

True

b)

False

75.

The nested branches can take on various forms, and the if-else branches may even use different variables, which are called Nested branches.

a)

True

b)

False

76.

A set of pre-written functions that carry out common tasks, that a programmer can use to improve productivity, is called a library.

a)

True

b)

False

77.

Special two-character sequence \n whose appearance in an output string literal causes the cursor to move to the next output line is called newline.

a)

True

b)

False

78.

The number of calculations required to solve a problem is a Floating-point literal.

a)

True

b)

False

79.

Words for carrying out a program's statements are Run, execute.

a)

True

b)

False

80.

Models the objects of a program is a class diagram.

a)

True

b)

False

81.

The fourth step of the waterfall approach checks that the programs correctly meets the goals is Epsilon.

a)

True

b)

False

82.

Indicates an unrepresentable or undefined value is a binary number.

a)

True

b)

False

83.

A function is a built-in zyFlowchart function that takes two arguments, lowValue and highValue, and returns a random integer in the range lowValue to highValue. Ex: RandomNumber(1, 10) returns a random integer in the range 1 to 10 is a Return variable.

a)

True

b)

False

84.

Assigns a variable with a value, such as x=5 is an assignment statement.

a)

True

b)

False

85.

Each time through a loop's statement is an interpreter.

a)

True

b)

False

86.

Using base two numbers, 0 and 1 is a function call.

a)

True

b)

False

87.

Eight bits, Ex: 10001001 is a byte.

a)

True

b)

False