ExamGecko
Home Home / Google / Associate Android Developer

Google Associate Android Developer Practice Test - Questions Answers, Page 10

Question list
Search
Search

List of questions

Search

Related questions











If you want get a debuggable APK that people can install without adb, in Android Studio you can:

A.
Select your debug variant and click Build Bundle(s) / APK(s) > Build APK(s).
A.
Select your debug variant and click Build Bundle(s) / APK(s) > Build APK(s).
Answers
B.
Click the Run button from toolbar
B.
Click the Run button from toolbar
Answers
C.
Select your debug variant and click Analyze APK.
C.
Select your debug variant and click Analyze APK.
Answers
Suggested answer: A

Explanation:

The Run button builds an APK with testOnly="true", which means the APK can only be installed via adb (which Android Studio uses). If you want a debuggable

APK that people can install without adb, select your debug variant and click Build Bundle(s) / APK(s) > Build APK(s). Reference:

https://developer.android.com/studio/run

To build a debug APK, you can open a command line and navigate to the root of your project directory. To initiate a debug build, invoke the assembleDebug task:

gradlew assembleDebug

This creates an APK named [module_name]-debug.apk in

[project_name]/[module_name]/build/outputs/apk/

Select correct statements about generated file. (Choose all that apply.)

A.
The file is already signed with the debug key
A.
The file is already signed with the debug key
Answers
B.
The file is already aligned with zipalign
B.
The file is already aligned with zipalign
Answers
C.
You can immediately install this file on a device.
C.
You can immediately install this file on a device.
Answers
Suggested answer: A, B, C

Explanation:

Reference:

https://developer.android.com/studio/run

Building your app from the command line, if you have a "demo" product flavor, then you can build the debug version with the command:

A.
gradlew assembleDemoDebug
A.
gradlew assembleDemoDebug
Answers
B.
gradlew installDemoDebug
B.
gradlew installDemoDebug
Answers
C.
both variants are correct.
C.
both variants are correct.
Answers
Suggested answer: C

Explanation:

Before immediately install build on a running emulator or connected device, installDemoDebug cause an APK building. Reference:

https://developer.android.com/studio/run

If no any folder like res/anim-<qualifiers>, res/drawable-<qualifiers>, res/layout-<qualifiers>, res/raw-<qualifiers>, res/xml-<qualifiers> exist in the project. Which folders are required in the project anyway? (Choose two.)

A.
res/anim/
A.
res/anim/
Answers
B.
res/drawable/
B.
res/drawable/
Answers
C.
res/layout/
C.
res/layout/
Answers
D.
res/raw/
D.
res/raw/
Answers
E.
res/xml/
E.
res/xml/
Answers
Suggested answer: B, C

Explanation:

Reference: https://developer.android.com/guide/topics/resources/localization

Assume that an app includes a default set of graphics and two other sets of graphics, each optimized for a different device setup:

res/drawable/

Contains default graphics.

res/drawable-small-land-stylus/

Contains graphics optimized for use with a device that expects input from a stylus and has a QVGA low-density screen in landscape orientation.

res/drawable-ja/

Contains graphics optimized for use with Japanese.

What happens if the app runs on a device that is configured to use Japanese and, at the same time, the device happens to be one that expects input from a stylus and has a QVGA low-density screen in landscape orientation?

A.
Android loads graphics from res/drawable/
A.
Android loads graphics from res/drawable/
Answers
B.
Android loads graphics from res/drawable-small-land-stylus/
B.
Android loads graphics from res/drawable-small-land-stylus/
Answers
C.
Android loads graphics from res/drawable-ja/
C.
Android loads graphics from res/drawable-ja/
Answers
Suggested answer: C

Explanation:

Reference:

https://developer.android.com/guide/topics/resources/localization

Assume that you have the following situation:

The app code calls for R.string.text_a

Three relevant resource files are available:

- res/values/strings.xml, which includes text_a in the app's default language, in this case English.

- res/values-mcc404/strings.xml, which includes text_a in the app's default language, in this case English.

- res/values-hi/strings.xml, which includes text_a in Hindi.

The app is running on a device that has the following configuration:

- The SIM card is connected to a mobile network in India (MCC 404).

- The language is set to Hindi (hi).

Which is the correct statement below?

A.
Android loads text_a from res/values/strings.xml (in English)
A.
Android loads text_a from res/values/strings.xml (in English)
Answers
B.
Android loads text_a from res/values-mcc404/strings.xml (in English)
B.
Android loads text_a from res/values-mcc404/strings.xml (in English)
Answers
C.
Android loads text_a from res/values-hi/strings.xml (in Hindi)
C.
Android loads text_a from res/values-hi/strings.xml (in Hindi)
Answers
Suggested answer: B

Explanation:

Android loads text_a from res/values-mcc404/strings.xml (in English), even if the device is configured for Hindi. That is because in the resource-selection process,

Android prefers an MCC match over a language match (as a priority Exception).

Reference:

https://developer.android.com/guide/topics/resources/localization

What is the placeholder tag <xliff:g> used for?

A.
To mark text that should not be translated.
A.
To mark text that should not be translated.
Answers
B.
To raise a translation priority to a higher level
B.
To raise a translation priority to a higher level
Answers
C.
To raise a quantity of translations for the string
C.
To raise a quantity of translations for the string
Answers
D.
To pick up and move sting translation from a different resource file
D.
To pick up and move sting translation from a different resource file
Answers
Suggested answer: A

Explanation:

Reference: https://developer.android.com/guide/topics/resources/localization

Choose the most correct statement.

A.
Android is a closed source, Linux-based software stack created for a wide array of devices and form factors.
A.
Android is a closed source, Linux-based software stack created for a wide array of devices and form factors.
Answers
B.
Android is a closed source, Windows-based software stack created for a wide array of devices and form factors.
B.
Android is a closed source, Windows-based software stack created for a wide array of devices and form factors.
Answers
C.
Android is an open source, Linux-based software stack created for a wide array of devices and form factors.
C.
Android is an open source, Linux-based software stack created for a wide array of devices and form factors.
Answers
D.
Android is an open source software stack created for a highly limited array of devices and form factors.
D.
Android is an open source software stack created for a highly limited array of devices and form factors.
Answers
Suggested answer: C

Explanation:

Reference: https://developer.android.com/guide/platform

Select correct statements about Hardware Abstraction Layer (HAL). (Choose two.)

A.
The HAL provides standard interfaces that expose device hardware capabilities to the higher-level Java API framework.
A.
The HAL provides standard interfaces that expose device hardware capabilities to the higher-level Java API framework.
Answers
B.
The HAL function both as apps for users and to provide key capabilities that developers can access from their own app. For example, if your app would like to deliver an SMS message, you don't need to build that functionality yourself -you can instead invoke whichever SMS app is already installed to deliver a message to the recipient you specify
B.
The HAL function both as apps for users and to provide key capabilities that developers can access from their own app. For example, if your app would like to deliver an SMS message, you don't need to build that functionality yourself -you can instead invoke whichever SMS app is already installed to deliver a message to the recipient you specify
Answers
C.
The HAL consists of multiple library modules, each of which implements an interface for a specific type of hardware component, such as the camera or bluetooth module. When a framework API makes a call to access device hardware,the Android system loads the library module for that hardware component.
C.
The HAL consists of multiple library modules, each of which implements an interface for a specific type of hardware component, such as the camera or bluetooth module. When a framework API makes a call to access device hardware,the Android system loads the library module for that hardware component.
Answers
D.
Using a HAL, not using a Linux kernel, allows Android to take advantage of key security features and allows device manufacturers to develop hardware drivers for a well-known kernel.
D.
Using a HAL, not using a Linux kernel, allows Android to take advantage of key security features and allows device manufacturers to develop hardware drivers for a well-known kernel.
Answers
Suggested answer: A, C

Explanation:

The system apps function both as apps for users and to provide key capabilities that developers can access from their own app. For example, if your app would like to deliver an SMS message, you don't need to build that functionality yourself ā€" you can instead invoke whichever SMS app is already installed to deliver a message to the recipient you specify Using a Linux kernel allows Android to take advantage of key security features and allows device manufacturers to develop hardware drivers for a well-known kernel. Reference:

https://developer.android.com/guide/platform

Custom views and directional controller clicks. On most devices, clicking a view using a directional controller sends (to the view currently in focus) a KeyEvent with:

A.
KEYCODE_DPAD_CENTER
A.
KEYCODE_DPAD_CENTER
Answers
B.
KEYCODE_BUTTON_START
B.
KEYCODE_BUTTON_START
Answers
C.
KEYCODE_CALL
C.
KEYCODE_CALL
Answers
D.
KEYCODE_BUTTON_SELECT
D.
KEYCODE_BUTTON_SELECT
Answers
Suggested answer: A

Explanation:

Reference:

https://developer.android.com/guide/topics/ui/accessibility/custom-views

Total 128 questions
Go to page: of 13