Official Bank 0/128

Google Developers Certification – Associate Android Developer (Kotlin and Java Exam) (Associate-Android-Developer) - Google Cloud Exam Questions

Last updated on June 20, 2026

97% Exam Compliance
128 Total Questions
1
Question
LiveData.postValue() and LiveData.setValue() methods have some differences. So if you have a following code executed in the main thread:
liveData.postValue("a"); liveData.setValue("b");

What will be the correct statement?
Options
A The value "b" would be set at first and later the main thread would override it with the value "a".
B The value "a" would be set at first and later the main thread would override it with the value "b".
C The value "b" would be set at first and would not be overridden with the value "a".
D The value "a" would be set at first and would not be overridden with the value "b".
Discussion (0 comments)

to join the discussion

Community Discussion

No discussions yet. Be the first to ask!

2
Question
If you added to your build.gradle file a room.schemaLocation:
android {
defaultConfig {
javaCompileOptions {
annotationProcessorOptions {
arguments = ["room.schemaLocation": "$projectDir/schemas".toString
()]
}
}
}
}
Then, you build your app or module.

As a result you got a json file, with such path to it: app/schemas/your_app_package/db_package/DbClass/DB_VERSION.json What are the correct statements about this file? (Choose all that apply.)
Select 3
Options
A The JSONObject "database" in this file usually should contain such objects, like "entities", "views",
"setupQueries", ets.
B It’s a file with Room-exported schema
C Main JSONObject in this file usually should contain a number "formatVersion" and a JSONObject "database"
Discussion (0 comments)

to join the discussion

Community Discussion

No discussions yet. Be the first to ask!

3
Question
The following code snippet shows an example of an Espresso test:
Options
A @Test
fun greeterSaysHello() {
onView(withId(R.id.name_field)).perform(typeText("Steve")) onView(withId(R.id.greet_button)).perform(click()) onView(withText("Hello Steve!")).check(matches(isDisplayed()))
}
B @Rule
fun greeterSaysHello() {
onView(withId(R.id.name_field)).do(typeText("Steve")) onView(withId(R.id.greet_button)).do(click()) onView(withText("Hello Steve!")).check(matches(isDisplayed()))
}
C @Test
fun greeterSaysHello() {
onView(withId(R.id.name_field)).do(typeText("Steve")) onView(withId(R.id.greet_button)).do(click()) onView(withText("Hello Steve!")).compare(matches(isDisplayed()))
}
Discussion (0 comments)

to join the discussion

Community Discussion

No discussions yet. Be the first to ask!

4
Question
Enable debugging on your device: If you are using the emulator, this is enabled by default. But for a connected device, you need to
Options
A enable debugging in the device developer options.
B enable transfer data from the device in usb connection options.
C enable connection in bluetooth options.
Discussion (0 comments)

to join the discussion

Community Discussion

No discussions yet. Be the first to ask!

5
Question
What is the incorrect statement about Data Access Object (androidx.room.Dao)?
Options
A Data Access Objects are the main classes where you define your database interactions. They can include a variety of query methods.
B An abstract @Dao class can optionally have a constructor that takes a Database as its only parameter.
C The class marked with @Dao should either be an interface or an abstract class. At compile time,
Room will generate an implementation of this class when it is referenced by a Database.
D It is recommended to have only one Dao class in your codebase for all tables.
Discussion (0 comments)

to join the discussion

Community Discussion

No discussions yet. Be the first to ask!

Finish Practice?

Are you sure you want to finish? This will end your practice session.