- Android Basics
- Android - Home
- Android - Overview
- Android - Environment Setup
- Android - Architecture
- Android - Application Components
- Android - Hello World Example
- Android - Resources
- Android - Activities
- Android - Services
- Android - Broadcast Receivers
- Android - Content Providers
- Android - Fragments
- Android - Intents/Filters
- Android - User Interface
- Android - UI Layouts
- Android - UI Controls
- Android - Event Handling
- Android - Styles and Themes
- Android - Custom Components
- Android Advanced Concepts
- Android - Drag and Drop
- Android - Notifications
- Location Based Services
- Android - Sending Email
- Android - Sending SMS
- Android - Phone Calls
- Publishing Android Application
- Android Useful Examples
- Android - Alert Dialoges
- Android - Animations
- Android - Audio Capture
- Android - AudioManager
- Android - Auto Complete
- Android - Best Practices
- Android - Bluetooth
- Android - Camera
- Android - Clipboard
- Android - Custom Fonts
- Android - Data Backup
- Android - Developer Tools
- Android - Emulator
- Android - Facebook Integration
- Android - Gestures
- Android - Google Maps
- Android - Image Effects
- Android - ImageSwitcher
- Android - Internal Storage
- Android - JetPlayer
- Android - JSON Parser
- Android - Linkedin Integration
- Android - Loading Spinner
- Android - Localization
- Android - Login Screen
- Android - MediaPlayer
- Android - Multitouch
- Android - Navigation
- Android - Network Connection
- Android - NFC Guide
- Android - PHP/MySQL
- Android - Progress Circle
- Android - ProgressBar
- Android - Push Notification
- Android - RenderScript
- Android - RSS Reader
- Android - Screen Cast
- Android - SDK Manager
- Android - Sensors
- Android - Session Management
- Android - Shared Preferences
- Android - SIP Protocol
- Android - Spelling Checker
- Android - SQLite Database
- Android - Support Library
- Android - Testing
- Android - Text to Speech
- Android - TextureView
- Android - Twitter Integration
- Android - UI Design
- Android - UI Patterns
- Android - UI Testing
- Android - WebView Layout
- Android - Wi-Fi
- Android - Widgets
- Android - XML Parsers
- Android Useful Resources
- Android - Questions and Answers
- Android - Useful Resources
- Android - Discussion
Android Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to Android. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Q 1 - What is a context in android ?
A - It is an interface to store global information about an application
B - It is used to create new components.
C - Android has two contexts, those are getContext() and getApplicationContext()
Answer : D
Explanation
Context is used to create new components or objects like views and it is used to start activity and services. Android has two kinds of contexts and those are getContext() and getApplicationContext().
Q 2 - What is the difference between margin and padding in android layout?
A - Margin is specifying the extra space left on all four sides in layout
B - Padding is used to offset the content of a view by specific px or dp
Answer : C
Explanation
Margin specifies the space left on four sides in the layout and padding specifies the exact position where the element going to be taking place in the layout.
Q 3 -What is ANR in android?
A - When the application is not responding ANR will occur.
B - Dialog box is called as ANR.
C - When Android forcefully kills an application, it is called ANR
Answer : A
Explanation
When an Application is not responding ANR will be occur, and it will stop the process or an application
Q 4 - How to store heavy structured data in android?
Answer : C
Explanation
We can store structured data in SQlite database only. SQlite database is very efficient and faster to read and store the data.
Q 5 -What is JNI in android?
Answer : D
Explanation
Java Native interfaces are used to call native/cross applications, which are written in C and C++ languages.
Q 6 - What is log message in android?
Answer : A
The log message is used to debug a program. Some of log messages are shown below
log.d-Debugging log log.i Informative log log.e-Error log log.w-Warning log log.v-verbose log
Q 7 - Data can be read from local source XML in android through
Answer : A
Using with XML resource parser, we can read local resource XML in android.
Q 8 - What is fragment life cycle in android?
C - onAttach()->onCreate() −> onCreateView() −> onActivityCreated() −> onStart() −> onResume()
Answer : C
Fragment life cycle is as shown below −
onAttach() OnCreate() onCreateView() onActivityCreated() onStart() onResume() onPause() onStop() onDestroyView() onDestroy() onDetach()
Q 9 - Why don't we give MIN SDK as 1 in android?
A - Android deprecated version
Answer : A
Android version 2.2 is deprecated so we don't need to call MIN version to be 1
Q 10 - How do you join two notifications in android?
A - Give same id for both notifications
B - Write notification code two times
Answer : E
Give same id for both notifications.
nm.notify(1,notification);
To Continue Learning Please Login
Login with Google