Please comment if you find any answer wrong or if there is any discrepancy. Thanks! 🙂 Here, we aim to please 😀
[quads id=1]
1) How many threads are created by asyncTask in Android?
a) Only one
b) Two
c) AsyncTask doesn’t have threads.
d) None of the above
Answer(s) : a) Only one
2) What is an HTTP client class in android?
a) httprequest (get/post) and returns response from server
b) Cookies management
c) Authentication management
d) None of the above
Answer(s) : a) httprequest (get/post) and returns response from server
[quads id=1]
3) What is AndroidManifest.xml ?
a) It has information about layout in an application.
b) It has information about activities in an application.
c) It has all the information ab66out an application.
d) None of the above.
Answer(s) : c) It has all the information about an application.
4) Do all components in Android run on the same thread?
a) It is based on the number of components because activity, service, receiver and content provider will create a thread by default internally.
b) Each application can have one process and one main thread created by default by the system.
c) Process or application by default will not have any thread.
d) None of the above
Answer(s) : b) Each application can have one process and one main thread created by default by the system.
[quads id=1]
5) You can shut down an Activity by calling its ______ method
a) onDestroy()
b) finishActivity()
c) finish()
d) None of the above
Answer(s) : c) finish()
6) Which component is not activated by an Intent?
a) Activity
b) Services
c) ContentProvider
d) BroadcastReceiver
Answer(s) : c) ContentProvider
[quads id=1]
7) What is the file format that Android uses to distribute and install apps?
a) APK
b) IPA
c) EXE
d) RAR
Answer(s) : a) APK
8) What is the first method called in the Activity Lifecycle of Android?
a) onStart()
b) onCreate()
c) onResume()
d) None of the above
Answer(s) : b) OnCreate()
[quads id=1]
9) What method gets called as the first indication that the user is leaving your activity?
a) onPause()
b)Â onStop()
c) onDestroy()
d) None of the above
Answer(s) : a) onPause()
[quads id=1]
10) What is the first method called in the lifecycle of a fragment in Android
a) onStart()
b)Â onCreate()
c)Â onCreateView()
d) None of the above
Answer(s) : d) None of the above
[quads id=1]