BM: Baca dalam Bahasa Melayu
World 12: Career Quest
Git interview questions
You will learn: short, clear answers to four classic Git questions.
The problem
The interviewer smiles: “So, what is HEAD: Git's "you are here" marker.?” Your mind goes blank. Don’t panic. Show it instead.
Tap the commit HEAD points at.
Watch
Question two: reset or revert? revert: Make a new commit that undoes an old one. adds a new commit that undoes an old one. Nothing is erased. So it is safe for shared work.
Predict
“Then when is reset the better choice?” Pick the answer you would give.
Pick one answer.
Try it
Question three: fetch or pull? fetch downloads the news but changes nothing. pull downloads it and joins it in. Sort each fact.
Drag a card into a box. Or tap the card, then tap the box.
Hint
Need a refresher? See “Fetch vs pull” in World 4.Predict
Last one: “Merge or rebase?” Pick the clearest answer.
Pick one answer.
Hint
World 3 has the full story: “Merge or rebase? Plus cherry-pick”.Check
Interviewers love honest, careful habits. Judge each answer.
Swipe right for good, left for needs work. Or use the buttons.
"I run git status before every commit."
You did it!
You can now answer four classic Git interview questions.
Go deeper (optional)
More classics: “What is a detached HEAD?” (World 2). “What does git stash do?” and “How do you fix a conflict?” (World 3). Practise each answer out loud, in two sentences. Then give a real example from your own project.
Bahasa Melayu
Penemu duga senyum: “Jadi, apa itu HEAD?” Fikiran anda kosong. Jangan panik. Tunjukkan sahaja.
Soalan kedua: reset atau revert? Revert (batalkan) tambah commit (titik simpan) baru yang membatalkan commit lama. Tiada apa dipadam. Jadi ia selamat untuk kerja yang dikongsi.
“Habis tu, bila reset lebih sesuai?” Pilih jawapan yang anda akan beri.
Soalan ketiga: fetch atau pull? fetch muat turun berita tapi tak ubah apa-apa. pull muat turun dan terus gabungkan. Susun setiap fakta.
Yang terakhir: “Merge atau rebase?” Pilih jawapan yang paling jelas.
Penemu duga suka tabiat yang jujur dan teliti. Nilai setiap jawapan.
Kini anda boleh jawab empat soalan temu duga Git yang klasik.
You finished this before. Practice is always welcome!
Official docs: git revert · git reset · git fetch · git pull · git merge · git rebase
You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?