Scope, Records, ASCII/Unicode, Strings & Logic.
(a) The part of the program where a variable is recognised / can be accessed.
(b) Memory efficiency (cleared when function ends) / Easier debugging (changes isolate to function).
ID (Int), Make (Str), Price (Real).
showroom to 12500.00.
RECORD Car
ID : Integer
Make : String
Price : Real
END RECORD
(b) showroom[5].Price = 12500.00
CHR(67)
ASC("D")
CHR(ASC("A") + 3)
phrase = "Computer Science"
phrase.lengthphrase.substring(0, 8)phrase.left(3)phrase.upper(a) ASCII is 7/8 bits (limited characters). Unicode is 16/32 bits (huge character set).
(b) Unicode supports all world languages and emojis.
(a) Type mismatch (Cannot add String + Int).
(b) num = int(input("Num: "))
isCold AND timerActive.
10 / 410 DIV 42.5 (Real/Float)
2 (Integer)
CONST VAT = 0.2 instead of a variable?
Prevents accidental changes to the value / Easier to update safely.