CA2 Flashcards
(206 cards)
State:
“True or false value”
Boolean
Define:
Character
“Single character which can be a letter, number or symbol”
Define:
Integer
“Whole numbers, positive or negative”
State:
“Any number, with or without decimal places, positive or negative”
Real/Float
Define:
String
“A group of characters stored together”
Define:
Immutable
“When the value of a number data type changes, a new object is created”
Define:
Casting
“Converting a variable from one data type to another”
Define:
Data Structures
“Collection of data objects which facilitate the storing and managing of data in a program”
State:
2 advantages of using data structures
- Optimise memory usage within a system
- Can be reused and compiled into libraries
State:
“A collection of data items, can be of different data types and items are accessed using each data items index value”
List
State:
“Contains a group of elements of the same data type”
Array
Define:
Dictionary
“A set of values, each with associated keys. Items are unordered and when accessed by the key, will return the associated value”
Define:
Index
“A numerical representation of an item’s position in a sequence”
Define:
Scope
“Where a variable can be accessed within a program”
Fill The Blank:
A ………. variable is only accessable in a pre-determined part of a program
Local
Fill The Blank:
Two variables can use the same identifier if they are in different ………. because they are in a seperate area in ………
Scopes, RAM
Fill The Blank:
The scope of a local variable is the ………… where it has been ………..
Subprogram, Declared
Fill The Blank:
The scope of a global variable is the …………. program
Complete
State:
Where global variables are declared
Start of the program
State:
Where local variables are declared
Declared within subroutines or programming blocks and can only be used within the scope it is declared in
Define:
Snakecase
Where words are delimited using underscores: Variable_a
Define:
Camelcase
All words are started with a capital letter, apart from the first word with no spaces: variableA
Define:
Pascalcase
words are started by capital letters: VariableA
Define:
Hungarian Notation
Describe the purpose and/ore type of variable at the start followed by a descriptor that states the function of the variable: iStudentMarks