binary calculations Flashcards

1
Q

how is binary addition different from denary addition

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

what is overflow in binary addition

A

overflow occurs when the result exceeds the number of bits available, e.g., adding two 8-bit numbers gives a 9-bit result

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

how do you add binary values

A

align both numbers, start from the rightmost bit, and use binary addition rules

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

what is a logical shift

A

it moves binary digits left or right, replacing emptied bits with 0

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

what is two’s complement

A

a method to represent negative binary numbers where the msb represents -128 instead of 128

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

how do you convert a binary value to two’s complement

A

find the first 1 from the right, leave it unchanged, and flip all bits to its left

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

how do you convert a negative value to two’s complement

A

find the binary equivalent (ignore the negative sign), apply two’s complement conversion, set the msb to 1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly