S3 Data Representation Flashcards
What is a logic gate?
Circuits built into computer chips
- they receive binary data
- apply a Boolean operation
- output a binary resume
Symbol for A AND B
A . B
Symbol for NOT A
Ā
Symbol for A OR B
A + B
Symbol for XOR B
A (+) B
Convert 300 kB to bits
300kB = 300 x 1000 = 300 000 bytes
300 000 bytes = 300 000 x 8
=2 400 000 bits
What is the order of the sizes of bits and bytes?
Bit
Nibble
Byte
Kilobyte
Megabyte
Gigabyte
Terabyte
What is 1+1 in binary?
What is 1+0 in binary?
10
01
What is 1011 after having a 2 place shift left?
What is the effect of this shift?
10
÷4
Why do programmers prefer hex?
- simpler to remember larger numbers
- Due to hex being shorter, less chance of input errors
- easier to convert between binary and hex than binary and decimal
What is hex 87 in decimal?
8 x 16 = 128
7 x 1 = 7
128 + 7 = 135
What is decimal 106 in hex?
106 ÷ 16 = 6 r 10
= 6A
What’s the largest number in hex?
FF
255
Convert binary 1011 1001 to hex
1011 1001
1011 = 11(dec) = B
1001 = 9
=B9
What is hex 8C in binary?
8 = 1000(binary)
C = 12(dec) = 1100
= 1000 1100