Multiple choice

onCreate() method of Service gets called when

  1. service is started through activity

  2. service binds with any component

  3. Both (1) and (2)

  4. None of these

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Service onCreate() is called whether the service is started via startService() or bound via bindService(). It's the initialization callback that runs once per service instance, unlike onStartCommand() which can run multiple times.