AP Courses AP Biology AP Biology Units AP Human Geography AP HUG Units AP Computer Science Principles AP CSP Units
Practice Daily Practice Practice by Course Practice by Topic Practice Tests
AP Exam Resources AP Exam Dates Registration Fees Scores & Credit What to Bring
Start Practicing → Login Register →

AP Computer Science Principles · Unit 2 · Data

Binary Numbers in AP CSP

Unit 2 · Binary · ~8 min read

Binary numbers are the foundation of digital data in AP Computer Science Principles Unit 2. A binary number uses only 0 and 1, and each place value is a power of 2.

On this page, you will learn what binary means, why computers use binary, how binary place values work, and how to avoid the common AP CSP mistake of reading binary like decimal.

Updated May 21, 2026Reviewed by APScore5 Editorial TeamAP CSP Unit 2 · Data

Base 2BitsPlace values0s and 1sAP-style practiceCommon mistakes
Step 1What binary meansBase 2 and bits. Step 2Why computers use itTwo stable states. Step 3Place valuesPowers of 2. Step 4PracticeTwelve topic MCQs.
Direct answer

In AP CSP, a binary number is written in base 2 using only 0 and 1. Each position is a power of 2, and computers use binary because digital hardware can reliably represent two states as bits.

Binary numbers AP CSP hero
Figure - Binary Numbers And Two State Hardware

Computers use binary numbers and two-state hardware to represent and process digital data.

Quick answer

What are binary numbers in AP CSP?

In AP CSP, a binary number is a number written in base 2. Binary uses only two digits: 0 and 1. Each position in a binary number represents a power of 2, such as 1, 2, 4, 8, and 16.

In one sentence: Binary numbers use only 0 and 1, and computers use binary because digital hardware can reliably represent two states.

Tiny example: The binary number 101 means 4 + 1, so it equals decimal 5.

Start the Unit 2 path on the AP CSP Unit 2 Data hub, then deepen storage units on bits and bytes.

Why binary

Why do computers use binary?

Computers use binary because digital hardware can represent two stable states. Those states can be interpreted as off/on, false/true, low voltage/high voltage, or 0/1.

Two-state hardware

Electronic circuits are easier to design reliably when they only need to distinguish between two states. It is much harder to build systems that must reliably distinguish ten different voltage levels for decimal digits.

Binary and digital data

Because computers use binary internally, all digital data can be represented as patterns of bits. Text, images, audio, video, numbers, and program instructions are all stored using 0s and 1s.

AP exam clue

If an AP CSP question asks why computers use binary, focus on two-state hardware and reliable representation. Do not say computers use binary because it is easier for humans.

Bits

Binary numbers and bits

A bit is one binary digit. It can be either 0 or 1. Binary numbers are made from sequences of bits.

TermMeaningAP CSP Example
BitOne binary digit0 or 1
Binary numberA base-2 number101
Bit patternA sequence of bits0101
Digital dataData represented with discrete valuesText, images, sound, files
Key rule: 1 bit has 2 possible values: 0 or 1.

For storage units, review bits and bytes.

Place values

How do binary place values work?

Binary place values double as you move left. Starting from the right, the place values are 1, 2, 4, 8, 16, 32, 64, and 128.

Binary place values chart
Figure - Binary Place Values Double Left

Binary place values double moving left, using powers of two to represent numbers.

Binary PlaceValue
Rightmost place1
Next place2
Next place4
Next place8
Next place16
Next place32
Next place64
Next place128

Example: binary 101

To read 101 in binary, place the values 4, 2, and 1 under the digits. Add the values under 1s: 4 + 1 = 5. So 101₂ equals 5₁₀.

Binary digit101
Place value421
Use it?yesnoyes

Example: binary 1010

For 1010₂, use place values 8, 4, 2, and 1. Add only the columns with 1s: 8 + 2 = 10.

Reading binary 1010 chart
Figure - Add Place Values Under Ones

To read binary numbers, add only the place values underneath the 1s.

Binary digit1010
Place value8421
Use it?yesnoyesno
Conversion

Binary to decimal basics

To convert a small binary number to decimal, write the binary place values and add only the values where the digit is 1.

  1. Start from the right.
  2. Write place values: 1, 2, 4, 8, 16...
  3. Match each binary digit to a place value.
  4. Add only the place values under 1s.
  5. Ignore zeros.
BinaryWorkDecimal
111
1022
112 + 13
10044
1014 + 15
10108 + 210
11118 + 4 + 2 + 115

Need step-by-step drills? Use the binary to decimal conversion guide.

Mistakes

Common mistakes about binary numbers

MistakeCorrection
Reading binary like decimal101₂ is 5₁₀, not one hundred one
Forgetting place values doubleBinary uses 1, 2, 4, 8, 16...
Adding zerosOnly place values under 1s count
Confusing bit and byteA bit is one 0 or 1; a byte is 8 bits
Forgetting base labelsUse 101₂ for binary and 5₁₀ for decimal when needed
Thinking binary only stores numbersAll digital data can be represented with bits
Assuming humans prefer binaryComputers use binary because hardware has two stable states

Some AP CSP classes also discuss overflow when a fixed number of bits cannot store a larger value. Treat overflow as a storage-limit idea, not the main point of this page.

Exam

How AP CSP tests binary numbers

AP CSP binary questions usually test small, clear ideas. You are not expected to do huge conversions by hand.

Question TypeWhat to Watch For
DefinitionBinary is base 2 and uses 0 and 1
Why binaryComputers use two-state hardware
Place valuesValues double moving left
Small conversionAdd place values under 1s
Bit capacityn bits can represent 2ⁿ patterns
Bit vs byte8 bits = 1 byte
AP exam tip: If the answer choices are close, write the place values. Most binary mistakes happen because students try to solve from memory instead of lining up the columns.

After this page, try the Unit 2 quiz or the 50-question practice set.

Practice

AP CSP practice questions: Binary numbers

These are short topic checks. For the full mixed Unit 2 set, use the 50-question practice page. Tap an answer to reveal the explanation. Choices shuffle on load.

A single binary digit is called a:

Q1

Why do computers use binary?

Q2

Which number system uses only 0 and 1?

Q3

What are the place values for the binary number 101 from left to right?

Q4

What is binary 101 in decimal?

Q5

What is binary 1010 in decimal?

Q6

How many different patterns can 3 bits represent?

Q7

Which statement is true?

Q8

Which is the best correction for the mistake "binary 100 is one hundred"?

Q9

Which AP CSP clue suggests binary place values?

Q10

A student has 4 bits. How many patterns can those bits represent?

Q11

Which example best shows digital data representation?

Q12
Before you leave

What you should be able to do now

Check each skill when you can explain it without looking at notes.

0 of 8 ready

Quick answers

Frequently asked questions

What is a binary number in AP CSP?

A binary number in AP CSP is a number written in base 2 using only the digits 0 and 1. Each position represents a power of 2, such as 1, 2, 4, 8, and 16.

Why do computers use binary?

Computers use binary because digital circuits can reliably represent two stable states, such as off/on or low voltage/high voltage. These states are represented as 0 and 1.

What is a bit?

A bit is one binary digit. It can have one of two values: 0 or 1.

How do binary place values work?

Binary place values double as you move left. Starting from the right, the values are 1, 2, 4, 8, 16, 32, and so on.

How do you convert binary 101 to decimal?

Binary 101 uses the place values 4, 2, and 1. Add the values under the 1s: 4 + 1 = 5, so 101₂ equals 5₁₀.

How many values can n bits represent?

n bits can represent 2ⁿ different patterns. For example, 3 bits can represent 2³ = 8 patterns.

What is the difference between a bit and a byte?

A bit is one binary digit, either 0 or 1. A byte is 8 bits.

What is the biggest binary mistake in AP CSP?

The biggest mistake is reading a binary number like a decimal number. For example, 101₂ is 5₁₀, not one hundred one.

Do I need to know huge binary conversions for AP CSP?

No. AP CSP usually focuses on small binary examples, place values, bit capacity, and why computers use binary.

What should I study after binary numbers?

After binary numbers, study bits and bytes, then binary-to-decimal conversion. Those pages build on the idea that computers represent data with bits.

Practice Questions Unit 2 Hub