🗒 Cheat Sheet← Lesson
BitWithBite
Git & GitHub Worksheet

🔘 Branches & Merging

Chapter: Git & GitHub · Level ★☆☆ · Time: 30 min
SCORE___ / 20
NameClassDate
After this worksheet you can
Create and switch branchesMerge branchesResolve conflictsWhy branch

🧠 Section A · Concept Check ● BEGINNER 4 × 1 = 4

1Create + switch in one:
2The default main line is usually:
3Combine a branch into main with:
4Same lines changed in both branches cause a:

🧮 Section B · Problem Solving ● INTERMEDIATE 2 + 3×3 = 11

5List branches with git .
6Modern switch command: git feat.
7Create feature branch, then merge it back - commands?
8What causes a merge conflict?
9How do you resolve one?

🚀 Section C · Challenge ● CHALLENGE 5

10Why branch instead of committing to main?
💭 Reflection — the most useful thing I learned:
A ___/4   B ___/11   C ___/5   Total ___/20 Teacher's Signature Parent's Signature
✂ answer key — fold or cut before handing out

1-A   2-A   3-A   4-A  |  5 branch   6 switch   7 = git checkout -b feat; ...work...; git checkout main; git merge feat   8 = Both branches edited the same lines differently   9 = Edit the marked file, keep the right code, add + commit  |  10 = Isolates experiments; main stays stable/deployable

📄 Need offline practice?Download the print-ready PDF or open the one-page cheat sheet.
⬇ Worksheet PDF 🗒 Cheat Sheet