Android Application Development (AND-401) — Question 76
Which of these is the correct explanation regarding the following methods?
(1)android.content.Context.sendBroadcast
(2)android.content.Context.startActivity
Answer options
- A. Both methods are defined by overloading.
- B. Both methods throw an exception.
- C. Both methods are asynchronous.
- D. Both methods are able to broadcast an Intent.
Correct answer: D
Explanation
The correct answer is D because both sendBroadcast and startActivity are designed to send Intents within the Android system. Options A, B, and C are incorrect as sendBroadcast and startActivity do not involve overloading, they do not both throw exceptions by design, and they are not asynchronous methods.