2. Where to begin?
• Primitive data types are predefined types of
data which are supported by a programming
language
• They then have broad data types within them,
which in turn have more specific types of data
associated with them
3. Data Type - Integer
• Represents whole numbers
• Can be positive or negative
• Can be represented in binary, denary or
hexadecimal, so long as they represent a
whole number
4. Data Type - Real
• Represents numbers which can have decimal
places within them
• Can be positive or negative
• Most often used for measurements, but they
do not store all the information ie
– 24.3km the Real data type would only store “24.3”
5. Why have Real and Integer?
• Speed – it takes longer to calculate Real data
as opposed to Integer
• Storage – Real data requires more storage
space than Integer
6. Data Type - Boolean
• Represents a true/false, yes/no value
• Can be used to simulate different
environments
– 1=on, 0=off
7. Data Type - String
• Used for storing any alphanumeric characters
– letters, numbers, symbols
8. Data Type – Date/Time
• Used for storing the date and time
• Can be represented in different formats
– DD/MM/YYYY
– DD/MM/YY
– MM/DD/YY