Day 3/100: Activity Lifecycle — The Diagram You've Seen 100 Times
This is Day 3 of my 100 Days to Senior Android Engineer series. Each post: what I thought I knew → what I actually learned → interview implications. 🔍 The concept Every Android developer has seen ...

Source: DEV Community
This is Day 3 of my 100 Days to Senior Android Engineer series. Each post: what I thought I knew → what I actually learned → interview implications. 🔍 The concept Every Android developer has seen this diagram: onCreate() ↓ onStart() ↓ onResume() ←──────────────────────┐ ↓ │ [Activity running] │ ↓ │ onPause() │ ↓ onRestart() onStop() ──────────────────────→ │ ↓ onDestroy() You could draw this in your sleep. I certainly could. The problem is that this diagram shows the happy path. It doesn't show what happens in the three scenarios that actually matter in production — and that every senior interview will eventually probe. 💡 What I thought I knew My mental model was: callbacks fire in a predictable sequence, each one is the right place to do certain things (init in onCreate, release in onDestroy), and as long as I follow the pattern, everything works. That model is mostly right. Mostly. 😳 What I actually learned The diagram has a ghost: the back stack The standard diagram shows a singl