Data Flashcards
Why do computers use
binary?
(Long explanation + short explanation)
We live in an analogue world since colours and sounds are all described by real numbers - there are an infinite number of them. (This is also referred to as continuous data.)
Digital signals and objects deal in the realm of the finite, meaning there is a limited set of values they can be.
Computers are made of digital switches (transistors) that can either be on or off. We use binary digits (bits) to represent their state.
Using binary values allows us to represent information on the transistors that make up a computer.
What is the relationship between
length of binary pattern and number of states that can be represented?
number of states that can be represented = 2^number of bits (in the binary pattern)
What are
decimal multiple of bytes used for?
data transmission speeds
i.e. kilobyte (kB), megabyte (MB) …
What are
binary multiples of bytes used for?
file sizes
i.e. kibibyte (KiB), mebibyte (MiB) …
What are the
multiples of bytes?
(in ascending order)
burger - byte
king - kibibyte/kilobyte
made - mebibyte/megabyte
great - gigibyte/gigabyte
toast - tebibyte/terabyte
previously - pebibyte/petabyte
(but - bit
now?) - nibble
Define
overflow error.
the error that ocurs when the number of bits reserved for the result of a calculation are not enough to store all the bits from the number
What is
two’s complement?
a method that allows for negative number representation where the most significant bit is negative
How would you
convert negative denary numbers to two’s complement?
(3 steps)
- Turn the negative denary number into a positive binary number.
- Flip the bits (0 -> 1, 1 -> 0).
- Add 1.
What are
binary shifts?
shifts that are used to move all the bits in a binary pattern left or right
What are
logical shifts
shifts that treats all the bits of a binary pattern in the same way, irrespective of what the pattern represents
Why can
loss of precision occur during a logical shift right?
because one or more of the right-most bits are discarded during the shift
What is special about an
arithmetic shift right?
and what is this good for?
the most significant bit is preserved
this is good because it gives us the ability to divide negative numbers
What are some
positives of hexadecimal?
(3)
- it takes up less space on the page to write numbers
- you make fewer mistakes when writing large numbers
- it is quicker to write down/copy/transcribe
What is
ASCII?
and what does it stand for?
a 7-bit character set
American Standard Code for Information Interchange
Define
colour depth.
the number of bits used to encode the colour of each pixel