Skip to content
Lesson 3: Data Types, Base 2 Arithmetic, and Boolean Logic
Remaining Time:
Navigation
Resources
Page Resource
Glossary
Section Status
Narration
Calculator
Notebook
Mute
Print
Static Page
Lesson 3: Data Types, Base 2 Arithmetic, and Boolean Logic
Overview
Identify and explain a variety of data types.
Bits
Base 2 System
Base 2 to Base 10 Conversion
Converting from Base 10 (Decimal) to Base 2 (Binary)
Hex (Base 16)
Bits, Continued
Data Types
Strings and Integers
Floating-Point Numbers
Normalizing the Format
Another Example
Boolean
Check Yourself: Using Bits
Solve basic math problems using a base 2 system.
Addition
Check Yourself: Addition
Subtraction
Going Further
More Examples
Negative Numbers
Check Yourself: Subtracting in Binary
Multiplication
Multiplying in Binary
Check Yourself: Multiplying in Binary
Division
Division in Binary
Check Yourself: Dividing in Binary
Demonstrate the use of signed/unsigned representation and perform 2’s complement.
Least Significant and Most Significant Digits
Signed Binary Numbers
1’s Complement
Adding Negative Values
2’s Complement
Check Yourself: Value Ranges
Demonstrate the ability to execute bit manipulation, such as left/right shift.
Intersection (&)
Check Yourself: Bitwise &
Union (|)
Check Yourself: Bitwise |
Symmetric Difference (^)
Check Yourself: Bitwise ^
Complement (~)
Check Yourself: Bitwise ~
Shifting Bits
Left Shift (<<)
Right Shift (>>)
Multiple Shifts
Masking
Explain how the AND, OR, NOT, and XOR logic works.
AND
OR
NOT
NAND
NOR
XOR
XNOR
Using Gates
Check Yourself: Using Gates
Lesson Conclusion
References
End of Lesson
End of Lesson
A
A word
:
A group of 16 bits.
ASCII (American Standard Code for Information Interchange)
:
A standard encoding schema that represents written characters in binary code.
B
Bit
:
A single-digit unit with only two possible values, derived as an abbreviation for
binary digit.
Byte
:
A group of 8 bits.
L
LSB (least significant bit)
:
In binary counting systems, the right-most bit in a number.
M
MSB (most significant bit)
:
In binary counting systems, the left-most bit in a number.
Mantissa
:
The fractional component of a number value in binary.
N
Nibble
:
A group of 4 bits.
del
C
+/-
/
7
8
9
*
4
5
6
-
1
2
3
+
.
0
=