Fichas
Computer Science Lesson 2
Fichas del conjunto (8)
- 1Comparison Operators== Equal To
!= Not Equal To
< Less Than
> Greater Than
<= Less Than/Equal To
>= Greater Than/Equal To - 2Arithmetic Operators+ Addition
- Subtraction
* Multiplication
/ Division
MOD Modulus, gives remainder
DIV Division, gives quotient
^ Exponentiation, gives powers. - 3Logical OperatorsAND Checks if both are true
OR Checks if either one is true
XOR Checks if one is true but not both
NOT Reverses the output
(NOT can be combined with other operators, e.g. NAND, NOR) - 4Data TypesBoolean, true/false (1/0)
Integer, a whole number
Real/Floating Point, an integer with decimal
Character, one single anything (e.g. '&')
String, more than one character grouped together - 5Variables/ConstantsA variable can change within the code.
A constant cannot, but CAN be changed OUTSIDE the code; VAT, for instance, is a constant--even if the government changes it, it will not change in the code, and will require an update to accommodate for this. - 6What is pseudocode?'Sort-of' code; code that will work in no language but can be adapted to work in any one of them. It can also be thought of as halfway between English and a programming language.
- 7Writing PseudocodeMake sure to close IF statements. It generally uses CAPITALS for operators (e.g. IF, THEN), putting THEN after such things as IF statements.
- 8What is a variable?In GCSE the definition might have simply been 'a value that can change whilst the code is running', but here we have to note that it is also a location in memory that does this.
Información
- Descripción
- A level Computing Fichas sobre Computer Science Lesson 2, creado por Calum Hawkesworth el 12/09/2017.
- Creado por
- Calum Hawkesworth
- Visitas
- 0
- Valoración