Android
AND-401 · Question #90
What does this code do? Intent intent = new Intent(); intent.setAction(Intent.ACTION_VIEW); startActivity(intent);
The correct answer is D. Starts an activity using an implicit intent. See the full explanation below for the reasoning.
Question
What does this code do? Intent intent = new Intent(); intent.setAction(Intent.ACTION_VIEW); startActivity(intent);
Options
- AStarts a sub-activity
- BStarts a service
- CSends results to another activity.
- DStarts an activity using an implicit intent.
How the community answered
(45 responses)- A4% (2)
- B7% (3)
- C13% (6)
- D76% (34)
Community Discussion
No community discussion yet for this question.