What happens when a variable is declared?
What are constants and how do they work?
Constants are named references to literal values. When the program is complied, any references to the constants are replaced by actual values in machine code.
What are the benefits of using constants?
What is a global scope?
It can be referred to anywhere in the program
What are features of local variables?
What is a parameter in a subroutine?
Part of the subroutine’s interface that allows values to be passed into the subroutine when it is called
What is an argument in a subroutine?
Value passed to a subroutine via a parameter
What is passing by value?
A literal value or copy of a data structure is given to the subroutine. A change made to this copy does not have any effect on the original.
What is passing by reference?
The subroutine is given a pointer to the address of the value/object in memory. If changes are made to the referenced value or data structure, they change the original so the change persists after the subroutine has finished.
What is exception handling?
Allows programmers to decide how a program should respond to the occurrence of an error that would otherwise lead to the program terminating abruptly.
What is a programming paradigm?
An approach to programming
What is procedural programming?
Type of imperative programming where programs are made up of “imperatives” that are run step-by-step
What does the structural approach to programming involve? (POLISH)
What are the advantages to the structured approach?
What is a hierarchy chart?
What are the advantages of subroutines?
What is a class?
The definition of an object. Classes define the attributes and methods that an object of the class will have.
What is an object?
A specific instance of a class resident in memory
What is instantiation?
The process of creating an instance of an object, belonging to a class, by invoking a constructor method
What is encapsulation?
Combing data with the procedures and functions that manipulate it to form a new data type
What are the properties of OOP?
What is information hiding?
Protects an object’s implementation and internal state from being accessed by other objects
What are the uses of information hiding?
Allows programmers to implement restrictions on how values are accessed and set. This is done through the use of access modifiers.
What are the access modifiers and their descriptions?