CS 399

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

An instance of a binary three with three internal nodes and four leaf node will be of height. 3 or 4 3 4 More than 4

3 or 4

Which Android Studio tool is used for creating a device emulator? SDK Manager AVD Manager Layout Manager Configuration

AVD Manager

1) Select the list of Android Architecture Concepts (C1 to C8) that are related to monitoring Lifecycle events. a) C1: Activity Lifecycle Event Handler Functions, C3: LifecycleOwner Interface & C5: savedInstanceState b) C1: Activity Lifecycle Event Handler Functions, C2: LifecycleObserver Interface & C3: LifecycleOwner Interface c) C4: Kotlin Companion object & C2: LifecycleObserver Interface d) C5: savedInstanceState & C6: ViewModel

Activity Lifecycle Event Handler Functions, C2: LifecycleObserver Interface & C3: LifecycleOwner Interface

Android Studio can be configured to watch for updates through: Dev Channel Beta Channel Stable Channel All channels including: Canary. Dev, Beta and Stable

All channels including: Canary. Dev, Beta and Stable

XML elements in Android Layout file are: Interpreted as Java code Are specifications of instances of classes defined in libraries used for UI definition May include information on placing the visual object on the application screen All items are correct

All items are correct

Versions of Android are identified by: Version Number Version Name API Level All of the above

All of the above

Which one of the following Kotlin language features help writing more concise code? Null safety When expression Type interface All of the above

All of the above

Which one of the statements are/is true about the following Kotlin expression. Expression: getOrElse (dice[i]) {0} It is a lambda expression It returns a 0 if the index 'I' exceeds the array boundaries It returns the value of 'dice[I]" if 'I' is within the array boundaries All of the options are correct.

All of the options are correct

1) Which one of the following is an example of a configuration change for an Android phone? a) Changing orientation of mobile phone b) Starting and stopping network connectivity c) Starting and stopping video buffering d) All of the options are valid

All of the options are valid

Which one of the followings is not a way for View object to communicate its size to its parent object? match_parent wrap_content An exact number All options are a valid way

All options are a valid way

Which one of the items below are among selections you make when creating an Android application project in Android Studio? API Level Activity Template Programing Language All options are correct

All options are correct

Which one of the followings Kotlin programming language features help writing more concise code? Null Safety When Expression Type Inference All options help more concise code

All options help more concise code

Which one of the following is likely to be a resource directory under Android Studio res directory? layout values drawables All three are options are likely resource directory

All three options are likely resource directory

Which one of the following options below is the selion(s) that must be made when creating an emulator in teh Android Studio? Device only Device and API level API Level Only HAXM

Device Name and API level

Which one of the following options below is the selection(s) that must be made when creating an emulator in Android Studio. Device Device and API level API Level HAXM

Device and API level

Which statement below is true about virtual machines? Code that runs on a virtual machine is portable across various platforms. Virtual machines provide an isolated environment for execution of programs. Virtual machine code is translated to a physical machine code before execution. All three statements are correct.

All three statements are correct

An IOT Android app is an example of: An Android application with only one activity An Android application that not have a visual component Both options are correct Both options are incorrect

An Android application that not have a visual component

Which one of the following options below is an intent type? Select the best answer Implicit Explicit Activity Both Implicit and explicit

Both Implicit and explicit

In Android Studio to run a program on an emulator the following selections are required. The SDK version The Virtual Device Both SDK version and the Virtual Device No selection is required

Both SDK version and the Virtual Device

In Android Studio a layout file may be edited using: Design tool Text tool Both design tool and text tool may be used Any text editor

Both design tool and text tool may be used

An activity is popped from the stack when: Back button on the device or on the UI is pushed When the finish function is called. Both options are correct Both options are incorrect

Both options are correct

The version of Kotlin plugin used in an Android project is specified in. AndroidManifest.xml Build.gradel (project) Build.gradel (module) In the resource package

Build.gradel (project)

Which one of the following selections from Android Studio design editor pallette does not create an instance of the EditText class? Password E-mail Plain Text Button

Button

1) Select the list of concepts (C1 to C8) that are related to saving the state of an Android Activity. The Activity can retrieve the saved state when it is recreated.

C5: savedInstanceState

1) Select the concept that is relevant to seamlessly accessing view components in layout files in a Kotlin code. a) C1: Activity Lifecycle Event Handler Functions b) C5: savedInstanceState a) C7: Synthetic View Binding b) C5: savedInstanceState

C7: Synthetic View Binding

1) If you use _______________ for accessing components in layout files you do not need synthetic view binding imports in you Kotlin file. a) C4: Kotlin Companion object b) C5: savedInstanceState c) C7: Synthetic View Binding d) C8: FindViewById

C8: FindViewById

This Android Studio Channel is a version of the software with all the latest features and bug fixes but may not be fully ready for production. Canary Channel Dev Channel Stable Channel Beta Channel

Canary Channel

To separate business logic from view controller logic the following Kotlin programing language construct may be used. Synthetic View Binding Companion Object Auto Casting None of the options are correct

Companion Object

Android view and viewGroup are based on ____ Gang of Four pattern Observer Composite State Template Method

Composite

Android responds to different screen sizes by adjusting the UI display and provides the best user experience for every screen size for mobile phones and tablets. True False

False

In Android Studio for each application there is one Gradle build script file that defines the build process. True False

False

It is a good practice to the keep all application logic in the view controller (MainActivity) True False

False

To call a method defined in a companion object you must instantiate the companion object class. True False

False

View and ViewGroup classes are direct subclasses of the Object class. True False

False

You cannot change the orientation of Linear Layout at runtime. True False

False

You can use FindViewById as an alternative approach to Kotlin Synthetic Binding feature. Dynamic Binding FindViewById ConstraintLayout None of the options are correct

FindViewById

You can use _______ as an alternative technique to Kotlin Synthetic Binding feature. Dynamic Binding FindViewById Constraint Layout None of the options is correct.

FindViewById

Which one of the followings is a variation of Linear Layout. Horizontal Dynamic Constraint None of the options is correct

Horizontal

The Android messenger object that does not specify the identity of the massage receiving component is: Intent object Implicit Intent object Explicit Intent Object Intent Filter

Implicit Intent object

Which one of the following items below is not a component of a Kotlin based Android application? Java Package Resource (res) Package Manifest File Kotlin Package

Java Package

1) This Kotlin programming language construct can be used to separate business logic form visual presentation in an Android application. a) C4: Kotlin Companion object b) C5: savedInstanceState c) C7: Synthetic View Binding d) C8: FindViewById

Kotlin Companion Object

Which one of the followings is correct regarding Kotlin language Type system? Select the best option that applies. Kotlin is a dynamic type language Kotlin is a static type language Kotlin is a dynamic type language with type inference. Kotlin is a static type language with type inference.

Kotlin is a static type language with type inference

Kotlin programming language provides three editions supporting execution of Kotlin programs on three different platforms. Which one of the followings is not among the three editions supported by Kotlin? Kotlin/JVM Kotlin/JS Kotlin/Native Kotlin/Unix

Kotlin/Native

Hardware drivers are part of the which layer in the Android SW Stack? Linux Kernel Android Runtime and Libraries Application Framework Android Runtime

Linux Kernel

Which one of the software layers below is at the bottom of the Android SW Stack? Application Linux Kernel Android Runtime and Libraries Application Framework

Linux Kernel

A TextView instance may include multiple instances of: ImageView instances ConstraintLayout instances View instances No Instance of any class listed in this question

No Instance of any class listed in this question

Which one of the followings is not true regarding Null Safety feature of Kotlin Programing language? Variables are assumed to be non-nullable. Non-nullable variables can not be assigned null value. Variables can be declared to be nullable. Because of this feature you never have null pointer exception.

Non-nullable variables can not be assigned null value

Which one of the classes below is not a subclass of Android View class? TextView ImageView ConstraintLayout Object

Object

The Android LifecycleObserver architectural component is based on ___________ GOF pattern. Composite Decorator Observer All options are invalid

Observer

Activities are grouped into __ and managed on a last-in-first-out basis: States Tasks Container Groups

Tasks

Which of the following statements is true regarding TextInputLayout class. Select the best choice. TextInputLayout is a subclass of EditText TextInputLayout is a subclass of LinearLayout TextInputLayout is a subclass of LinearLayout which wraps an EditText component. TextInputLayout is a subclass of EditText which wraps a LinearLayout component.

TextInputLayout is a subclass of LinearLayout which wraps an EditText component.

Which one of the following Android Studio UI components is not for text data entry. TextInputLayout PlainText Password TextView

TextView

Which one of the following Android Studio UI components is not for text data entry? PlainText TextView Password E-mail

TextView

Which one of the followings is not supported by Kotlin built-in types? Numeric Character TextView Array

TextView

A ConstraintLayout instance may include multiple instances of: TextView instances and ImageView instances only TextView instances only ImageView instances only TextView instances, ImageView instances and instances of ViewGroup classes

TextView instances, ImageView instances and instances of ViewGroup classes

The first activity that is added to a task is: The activity with the highest priority The activity that is marked as the LAUNCHER activity in the application manifest The activity that is loaded in the onCreate method of the MainActivity class None of the options are correct

The activity that is marked as the LAUNCHER activity in the application manifest

Each Android application in Android Studio has an AndroidManifest.xml file which includes all the components of the application. True False

True

In Android Studio Hardware selection window for phone device emulators the play Store attribute shows if the emulator can download apps from Google Play Store. True False

True

In Android Studio after installation of a new version of Kotlin plugin configuration of applications that were built using older versions of the plugin must be changed to use the new version of the plugin. True False

True

In Android Studio choosing the Project View (instead of Android View) shows the project directory structure as it is stored on the disk. True False

True

In Kotlin programming language every type is implemented as a class. True False

True

In Kotlin programming language every variable is of a particular type and once the type is assigned it cannot be changed. True False

True

Kotlin code is first translated to JavaByteCode and then JavaByteCode is translated to DaxByteCode. True False

True

Lamda expressions enable you to treat functionality as method argument, or code as data True False

True

The Kotlin "'when' construct can be used as a statement or as an expression. True False

True

The TextInputLayout widget at runtime shows a floating label when the hint is hidden due to user inputting text. True False

True

To use the LifecycleObserver Android Architectural Component you must declare a class that implements the LifecycleObserver interface True False

True

You can add View objects to a Layout View object at runtime. True False

True

You can have more than one version of Android Studio installed at one time. True False

True

You can use a when expression in the left side of an assignment to assign value to a variable. True False

True

Which one of the following is the most critical in the design and implementation of Android application User Interface? UI should be designed to adjust to varying screen size UI should use and appropriate theme UI should be based on new packages supporting UI widgets and functionality None of the items listed are critical

UI should be designed to adjust to varying screen size

An instance of TextView class is also an instance of: View class only View class and Object class only View class, ViewGroup class and Object class View class and ViewGroup only

View class and Object class only

Which one of the following can be used in Kotlin code to access an Android Studio UI object? The class name android:id attribute android:ems attribute android.name attribute

android:id attribute

Which one of the following is not a component of the Android project resource module? values mipmap androidManifest layout

androidManifest

Which one of the followings is not a component of the Android project resource module? values mipmap androidManifest layout

androidManifest

Which one of the followings is not an attribute of EditText class? orientation hint inputType layout_width

orientation

In Android applications the following functions is used for specifying the layout xml file for the initial screen displayed by the application. Snackbar.make onOptionsItemSelected setContentView None of the listed functions

setContentView

The _________ method is a method of Button class which may be called to set the behavior for a Button widget. makeText MakeButton setOnClickListener setEventListner

setOnClickListener

1) A configuration change for an Android phone causes Android Activities running on the phone to go through a complete life cycle. a) True b) False

true

Which one of the Kotlin variable declarations is invalid? var myNum: Int = 9 var myNum: Int = 9 var myNum = 9 var myNum

var myNum

_______ is a valid value for the orientation attribute of Linear Layout. "@+id/MyLinearLayout" "vertical" "wrap_content" None of the options is correct

vertical

Which one of the following name spaces below define components that only impact what your see in the tools view? They have no impact on the application at runtime. xmlns:android xmlns:app xmlns:tools All name spaces impact application at runtime

xmlns:tools

In Android Studio the number of layout files created for the Empty Activity template is: 0 1 2 3

1

Two aspects of keeping your installed versions of Android Studio up-to-date are keeping the version of Android Studio software and ____ up-to-date Android Studio Libraries Android Studio Plugins Android Studio Tools None of the above

Android Studio Plugins

Which one of the statements below is true regarding HAXM and Android device emulator? HAXM is an Android device emulator Android device emulators use HAXM to accelerate their processing HAXM and Android device emulator work independently HAXM is a debugging tool for applications running on Android device emulators

Android device emulators use HAXM to accelerate their processing

Which one of the software layers below is below the application layer in the Android SW Stack? Drivers Linux Kernel Android Runtime and Libraries Application Framework

Application Framework

Supports for changing the language of your Android App for internationalization is provided by: Resource values colors component Resource values strings component Resource mipmap component Resource values styles component

Resource values strings component

When an Android application is active on the device it is in ___ activity lifecycle state: Resumed Created Started Paused

Resumed

When an Android application is active on the device it is in ____ activity lifecycle state: Created Started Resumed Paused

Resumed

Methods defined in a Kotlin class companion object are similar to the __ methods in java Private Protected Public Static

Static

1) For an Android Activity to receive updates on a particular data in a ViewModel it must: i. Have a reference to the ViewModel instance. ii. ___________ the data in the ViewModel. a) Subscribe to b) Publish c) Explicitly access d) Wait for the next cycle to get

Subscribe to

This is a Kotlin compiler based tool that looks into the layout xml file and gets the references you need. Dynamic Binding Synthetic Binding ID Lookup Non of the options are correct

Synthetic Binding

1) To allow access to the view components in a layout files in Kotlin code via synthetic view binding, the followings conditions must hold. i. The component in the layout file must have id ii. The Kotlin file must have an import synthetic binding statement for the layout file.

True

A binary tree data structure can be implemented using Composite Design Pattern where leaf and internal node components in the binary tree respectively map to the leaf and composite class in the GOF composite Pattern structure. True False

True

Android Runtime (ART) includes core libraries and the Virtual Machine. True False

True

Android applications can work together to create a user experience. True False

True

ConstraintLayout and CoordinatorLayout are subclasses of the ViewGroup class. True False

True

Which architectural component should be used for data management logic? ViewModel LifecycleObserver Android Resource Manifest File

ViewModel

1) This feature of Android platform provides a mechanism to store the state of an Activity as <key, value> pairs when the activity is being destroyed. You can use the stored information to restore the state of Activity upon recreation. a) C4: Kotlin Companion object b) C5: savedInstanceState c) C7: Synthetic View Binding d) C8: FindViewById

a) C5: savedInstanceState

1) This Android Architectural component encapsulates all the data management code of the application. It broadcasts changes to the data to all software components which subscribe to the change. a) C4: Kotlin Companion object b) C5: savedInstanceState c) C6: ViewModel d) C8: FindViewById

a) C6: ViewModel


Set pelajaran terkait

Module 6 TR Puzzle (Extra Credit)

View Set

Fingertip units for topical dosing

View Set

Chemistry Honors: Unit 3 Test (9.1-14.3)

View Set

1 week/1st day/context=voracious,indiscriminate, eminent, steeped, replete, I eat my humble pie ( idiom) from the book 1100 Words You Should Know by Barron's

View Set

Chapter 35: Caring for Clients with HIV/AIDS

View Set

Complétez par y,en, le, la, l', les, lui, leur

View Set

Security+ Network Security Fundamentals Chapter 8 & Chapter 7

View Set