Free Google Associate-Android-Developer Exam Actual Questions

The questions for Associate-Android-Developer were last updated On Apr 28, 2024

Question No. 1

What is a correct part of an Implicit Intent for sharing data implementation?

Show Answer Hide Answer
Correct Answer: D

Create the text message with a string

val sendIntent = Intent().apply { action = Intent.ACTION_SEND

putExtra(Intent.EXTRA_TEXT, textMessage) type = 'text/plain'

}


https://developer.android.com/guide/components/fundamentals

Question No. 2

By default, the notification's text content is truncated to fit one line. If you want your notification to be longer, for example, to create a larger text area, you can do it in this way:

Show Answer Hide Answer
Question No. 3

Select correct demonstration of WorkRequest cancellation.

Show Answer Hide Answer
Correct Answer: C

Working with WorkManager, from the 2018 Android Dev Summit WorkManager: Beyond the basics, from the 2019 Android Dev Summit


https://developer.android.com/reference/androidx/work/WorkManager?hl=en

Question No. 4

In general, you should send an AccessibilityEvent whenever the content of your custom view changes. For example, if you are implementing a custom slider bar that allows a user to select a numeric value by pressing the left or right arrows, your custom view should emit an event of type TYPE_VIEW_TEXT_CHANGED whenever the slider value changes. Which one of the following sample codes demonstrates the use of the sendAccessibilityEvent() method to report this event.

Show Answer Hide Answer
Correct Answer: B

Question No. 5

The easiest way of adding menu items (to specify the options menu for an activity) is inflating an XML file into the Menu via MenuInflater. With menu_main.xml we can do it in this way:

Show Answer Hide Answer