D278 Scripting and Programming Foundations
Questions and Correct Answers
input
A program gets data, perhaps from a file, keyboard, touchscreen, network, etc.
process
A program performs computations on that data, such as adding two values like x + y.
Output
A program puts that data somewhere, such as to a file, screen, network, etc.
variable
It is a named item used to hold a value.
flowchart
A graphical language for creating computer programs.
Program
A list of statements, each statement carrying out some action and executing one at a time.
Run, execute
Words for carrying out a program's statements.
String literal
Text (characters) within double quotes.
Characters
,Any letter (a-z, A-Z), digit (0-9), or symbol (~, !, @, etc.).
newline
Special two-character sequence \n whose appearance in an output string literal causes the cursor
to move to the next output line.
comment
Text a programmer adds to a program, to be read by humans (other programmers), but ignored
by the program when executing.
Moore's Law
Engineers have reduced switch sizes by half about every 2 years.
bit
A single 0 or 1.
byte
Eight bits. Ex. 11000101
ASCII
American Standard Code for Information Interchange. Code that is the numerical representation
of a character. Ex. Z would be stored in a computer as 1011010.
Pseudocode
Text that resembles a program in a real programming language but is simplified to aid human
understanding.
, assignment statement
Assigns a variable with a value, such as X=5. left side must be ONE variable. right side is an
expression
variable declaration
declares a new variable, specifying the variable's name and type.
integer
Variable type that can hold whole numbers.
Expression
a combination of items, like variables, literals, operators, and parentheses, that evaluates to a
value
Identifier
A name created by a programmer for an item like a variable or function. Must be a sequence of
letters, underscores, and digits and must start with a letter. They are case sensitive. Special
characters, reserved words, and having spaces are not allowed
Reserved word (or keyword)
A word that is part of the language, like integer, Get or Put. These words cannot be used as an
identifier.
Naming conventions
A set of style guidelines defined by a company, team, teacher, etc., for naming variables.
Questions and Correct Answers
input
A program gets data, perhaps from a file, keyboard, touchscreen, network, etc.
process
A program performs computations on that data, such as adding two values like x + y.
Output
A program puts that data somewhere, such as to a file, screen, network, etc.
variable
It is a named item used to hold a value.
flowchart
A graphical language for creating computer programs.
Program
A list of statements, each statement carrying out some action and executing one at a time.
Run, execute
Words for carrying out a program's statements.
String literal
Text (characters) within double quotes.
Characters
,Any letter (a-z, A-Z), digit (0-9), or symbol (~, !, @, etc.).
newline
Special two-character sequence \n whose appearance in an output string literal causes the cursor
to move to the next output line.
comment
Text a programmer adds to a program, to be read by humans (other programmers), but ignored
by the program when executing.
Moore's Law
Engineers have reduced switch sizes by half about every 2 years.
bit
A single 0 or 1.
byte
Eight bits. Ex. 11000101
ASCII
American Standard Code for Information Interchange. Code that is the numerical representation
of a character. Ex. Z would be stored in a computer as 1011010.
Pseudocode
Text that resembles a program in a real programming language but is simplified to aid human
understanding.
, assignment statement
Assigns a variable with a value, such as X=5. left side must be ONE variable. right side is an
expression
variable declaration
declares a new variable, specifying the variable's name and type.
integer
Variable type that can hold whole numbers.
Expression
a combination of items, like variables, literals, operators, and parentheses, that evaluates to a
value
Identifier
A name created by a programmer for an item like a variable or function. Must be a sequence of
letters, underscores, and digits and must start with a letter. They are case sensitive. Special
characters, reserved words, and having spaces are not allowed
Reserved word (or keyword)
A word that is part of the language, like integer, Get or Put. These words cannot be used as an
identifier.
Naming conventions
A set of style guidelines defined by a company, team, teacher, etc., for naming variables.