Android Programming Fundamentals
Test your knowledge of Android application development including architecture, components, manifest file, resources, and activity lifecycle.
Questions
Developers can build android applications on _________ operating systems.
- Microsoft Windows XP or higher
- Mac OS 10.5.8 or higher
- Linux 2.7 or higher
- All of the above
How many layers does android architecture have?
- 1
- 2
- 3
- 4
_________ are not a component of android application.
- Activities
- Services
- Broadcast receivers
- None of these
Which of the following statements is correct about manifest file?
- One must save all the projects in manifest file.
- All the backup versions will be stored in manifest file under manifest directory.
- All the components of an android application must be declared in Androidmanifest.xml file.
- There is no manifest file in android development.
How many sections does android architecture have?
- 2
- 3
- 4
- 5
Manifest.xml file resides in
- /main folder
- /start folder
- the root
- anywhere on desktop
_____________ are not a resource of an android application.
- User interface strings
- Bitmaps
- Colours
- Smartphones
- Layout definitions
Which of the following tags is not present in manifest file?
- <activity>
- <services>
- <os>
- <provider>
- <receiver>
Which is the the first callback method when an activity is created?
- Create()
- onCreate()
- Start()
- onStart()
Which of the following statements is correct about application resources?
- All the resources should be placed directly under the root directory.
- All the resources should be placed directly under the res/ directory.
- You should place each type of resource in a specific directory of your project's res/ directory.
- You can define your own user defined directories and place all the resources over there.
- None of these
Find the odd one out.
- anim/
- colour/
- menu/
- java/
- layout/
Which of the following options is not a correct callback method in an activity class?
- onCreate()
- onStart()
- onResume()
- onInterrupt()
Match the following:
| (a) Activities | (i) Handle data and database management issues |
| (b) Services | (ii) Handle user interaction to smartphone screen and also dictate the UI |
| (c) Broadcast receivers | (iii) Handle background processing associated with an application |
| (d) Content providers | (iv) Handle communication between android OS and applications |
- (a) – (ii), (b) – (iii), c – (iv), d – (i)
- (a) – (iii), (b) – (ii), c – (iv), d – (i)
- (a) – (i), (b) – (iv), c – (iii), d – (i)
- None of these
What is the name of the window where all the event messages will be displayed upon execution of the code from an eclipse IDE?
- Log window
- Log cat
- Error log
- Message log
- Log
Match the callback methods in an activity class with their description.
| (a) onCreate() | 1. It is called when the first activity is created. |
| (b) onStart() | 2. It is called when activity restarts after stopping it. |
| (c) onResume() | 3. It is called before the activity is destroyed by the system. |
| (d) onPause() | 4. It is called when the activity is no longer visible. |
| (e) onStop() | 5. It is called when the activity becomes visible to the user. |
| (f) onDestroy() | 6. It is called when the user starts interacting with the application. |
| (g) onRestart() | 7. When It is called, the paused activity does not receive any further user input and cannot execute any code. |
- a – 1; b – 5; c – 6; d – 7; e – 4; f – 3; g – 2
- a – 2; b – 5; c – 6; d – 7; e – 4; f – 3; g – 1
- a – 2; b – 4; c – 6; d – 7; e – 5; f – 3; g – 1
- None of these