Data Types Flashcards
Variables
A named space in memory, large enough to store a single piece of data. Each variable has a data type
Constant
A named space in memory with a value that can never change while the program is running. Useful for pi or VAT.
The python language does not allow for constants but some other languages do
Data type examples
Boolean, character, integer, real, string
Boolean
Can either be true or false
Character
A single letter, punctuation mark, space, number, etc.
Integer
Whole numbers (positive , negative, zero)
Real
Decimal numbers (positive or negative, can be zero)
String
Collection of characters
Declaratiob
Code thar causes a variable to exist. Once a variable has been declared, it can be used. Trying to use a variable before it has been declared will cause as error
Assignment
The process of putting a value into a variable. Most languages use a single equals = to do this.