Week 2 Flashcards
Assigned name of a memory address?
Identifier
Name for language used for describing the syntax and rules of another language?
Metalanguage
Proper term for calling a function?
Invoking
Initialising memory for a type of data and an identifier
Declaration
A function’s collective statements between curly braces?
Body
Memory location for which data can be changed?
Variable
Memory location for which data cannot be changed?
Constant
Who calls the main function?
The OS
The operator = is referred to as?
Assignment operator
A sequence of identifiers and/or literals with operators that returns a datum?
Expression
The act of computing an expression?
Evaluation
Raw data that is not referred to by an identifier?
A literal
Conjoining literals and identifiers of string data type?
Concatenation
“…” are used to embrace which literal?
Strings
‘…’ are used to embrace which literal?
Chars
The part of the function where its identifier and its parameters are declared?
Header
The entirety of a function consisting of its header and body?
Definition
The data passed to functions when they are invoked?
Arguments
A single executable line of code postfixed by a semicolon?
Statement
A collection of statements embraced by {…}?
Compound statement, or a body, or a block
A statement consisting only of a semi-colon?
A null statement
The name of a string with no characters?
Null string
The integer returned by the main function on execution?
The exit status
Traditionally the main function returns what integer when it executes with no errors?
0
The five kinds of statements allowed within a block?
Null statements, assignment statements, declarations, executable/output statements, compound statements
The :: operator is referred to as?
The scope resolution operator
The «_space;operator referred to as?
The insertion operator
The»_space; operator referred to as?
The extraction operator
include <…> is an example of?
A preprocessor directive
The term “std” is an example of a…?
Namespace
What are the four integral data types?
Char, short, int, long
Reserved word for an integral data type whose range includes only positive integers?
Unsigned
Smallest integral data type and its range?
Char: signed -128 - 127, unsigned 0 - 255
What is the result of storing values out of the range of a memory’s data type?
Overflow
The three data types that represent real numbers?
Float, double, long double
How are real numbers stored?
As an integral part and a fractional part
Dividing a real number by zero returns?
Inf
Dividing an integer by zero results?
Error
The ++ operator is referred to as?
The increment operator
7++ and ++7 are different how?
++7 the increment is executed prior and the integer is always 8
The - - operator is referred to as?
The decrement operator
Converting a literal, variable or constant to another data type at run time is called?
Type casting
The compiler process that assigns data types on inference?
Type coercion
How many ways to declare a variable / constant?
3
Declaration with {…}?
Uniform
Declaration with (…)?
Implicit
Declaration a = 0?
Explicit
Expression with values of varying data types?
Mixed type expression
Expressions of integers and real numbers coerce as?
Real numbers
Real numbers that are coerced to integers are said to have undergone?
Truncation
Identifiers can only consist of?
Characters A-Z, a-z, 0-9, _
Identifiers can only begin with?
Characters A-Z, a-z
The term for the order in which operators are executed?
Order of precedence
The order of predence is as follows?
Unary operators (-17, ++9, - -34)
Brackets ()
Binary operators *, /, %
Binary operators +, -
std::fixed does what?
Represents real and integer numbers with floating points
std::scientific does what?
Represents floats in scientific notation, i.e., 2.134x10^12 or 2.134E12
std::setprecision(n) does what?
Formats real numbers to n decimal places
std::showpoint does what?
Displays both integers and real numbers with floating point
Library needed for formatting outputs of numbers?
iomanip
std::setw(n) does what?
Generates a field of whitespaces of at least n width in which strings after a trailing insertion operator («) will print right justified
Meaning ascribed to code and its rules by programmers and compilers?
Semantics
Rules and symbols that dictate how a language or its parts are written?
Syntax
What terminates a statement?
;
What kind of statement doesn’t need terminating?
Compound statement {…}
What part of the compilation process handles #includes?
Preprocessor