Data representation and data types Flashcards
What is a bit?
A bit is a single digit that can be 1 or 0 (on or off)
What is a nibble?
A nibble is an arrangement of 4 bits, with 16 possible combinations.
What is a byte?
A byte is an arrangement of 8 bits, with 128 possible combinations.
What is a word in computing?
A word is the amount of data that a CPU can process within a certain amount of time. It can be 64 or 128 bits long.
How many bits are in a byte
8 bits
How many bits are in a nibble
4 bits
How many bytes are in a Kilobyte (KB)
1024 bytes
How many KB are in a megabyte (MB)?
1024 KB
How many MB are in a gigabyte (GB)?
1024 MB
How many GB are in a terabyte (TB)?
1024 GB
How many TB are in a petabyte (PB)?
1024 TB
What is the difference between Mb and MB?
Mb stands for megabits, while MB stands for megabytes. To convert Mb to MB, divide by 8.
What is a character data type?
A single letter, digit, or punctuation mark (e.g., ‘A’, ‘4’, ‘!’).
What is a string
A sequence of characters (e.g., “computer”, “science”).
What is an unsigned integer?
A whole number that is always positive (e.g., 42, 11, 1).
What is a signed integer?
A whole number that can be positive or negative (e.g., 12, -18, 0).
What is a real number
A fractional or decimal number(e.g., 15.6, -12.25)
What is a boolean
A data type that represents either true or false (1 or 0)
How do computers represent characters
Each character is mapped to a binary number for standardized communication between systems.
What is ASCII
A character encoding system that uses 8 buts to represent 255 characters, mainly in the English language
What is Unicode
A character encoding system that supports multiple languages and symbols it currently uses 21 bits (3 bytes)
What is the amin difference between ASCII and Unicode
ASCII can only represent 255 characters, while Unicode supports a vast range of characters from different languages.
Why do computers use binary instead of decimal
Computers store data using 1s and 0s because they represent electrical on/off states
What is the binary representation of the number 3
00000011