Android developer - Interview questions
Tags: android, mobile, kotlin, programming
Published: 2021-12-16 13:43:35

Hello, recently I made a job switch and have attended interviews in various companies. I would like to share the list of questions and topics I came across during the process.

__Programming Basics__

1. what is the difference between final, finally and finalize?[Answer](https://www.javatpoint.com/difference-between-final-finally-and-finalize)
2. Explain [abstraction](https://www.journaldev.com/33191/what-is-abstraction-in-oops#:~:text=Your%20car%20is%20a%20great,completely%20hidden%20from%20the%20user.) in OOPS concept
3. Explain [inheritance](https://www.guru99.com/java-class-inheritance.html) in OOPS concept
4. How to achieve [polymorphism](https://www.geeksforgeeks.org/polymorphism-in-java/) and it's types?
5. What is [Interface](https://www.javatpoint.com/interface-in-java) in Java?
6. Can we create Object for abstract class? No, we can't create. [Explanation](https://www.tutorialspoint.com/can-we-create-an-object-of-an-abstract-class-in-java#:~:text=No%2C%20we%20can%27t%20create,object%20of%20an%20abstract%20class.&text=The%20reference%20variable%20is%20used,is%20known%20as%20Abstract%20class.)
7. Can we pass null value into HashMap?[Answer](https://stackoverflow.com/questions/15091148/hashmaps-and-null-values)
8. Different types of [Exceptions](https://www.geeksforgeeks.org/types-of-exception-in-java-with-examples/https://www.geeksforgeeks.org/types-of-exception-in-java-with-examples/).
9. Difference between array and arrayList. [Answer](https://www.javatpoint.com/array-vs-arraylist-in-java#:~:text=Array%20is%20a%20fixed%20length,primitives%20and%20objects%20in%20Java.)
10. Difference between serializable and parcelable. [Answer](https://www.tutorialspoint.com/difference-between-parcelable-and-serializable-in-android)

__Android questions__

1. How to add multiple fragments in single activity? [Answer](https://blog.criarsolutions.com/displaying-multiple-fragments-in-a-single-activity-android-789774baaefc)
2. Difference types of [services](https://developer.android.com/guide/components/services) in android?
3. How to create a custom view and custom widget in android? [Custom View](https://www.raywenderlich.com/142-android-custom-view-tutorial), [Custom widget](https://developer.android.com/guide/topics/appwidgets#use_the_appwidgetprovider_class_to_handle_widget_broadcasts)
4. How to update a single item in recyclerView? [Answer](https://stackoverflow.com/questions/32457406/how-to-update-refresh-specific-item-in-recyclerview#:~:text=You%20can%20use%20the%20notifyItemChanged,item%20at%20position%20has%20changed.)
5. Scope functions in Kotlin. [Docs](https://kotlinlang.org/docs/scope-functions.html)
6. Different types of Launch modes in android. [Answer](https://medium.com/mindorks/android-launch-mode-787d28952959)
7. How to check whether the lateinit variable is initialized? [Answer](https://stackoverflow.com/questions/37618738/how-to-check-if-a-lateinit-variable-has-been-initialized)
8. What is Elvis operator in kotlin? [Answer](https://www.javatpoint.com/kotlin-elvis-operator)
9. What is MultiDex in android? [Explanation](https://blog.mindorks.com/understanding-multidex-in-android)
10. Explain LiveData and it's types in android. [Explanation](https://www.raywenderlich.com/10391019-livedata-tutorial-for-android-deep-dive)
11. Difference between App bundle and APK. [Answer](https://stackoverflow.com/questions/52059339/difference-between-apk-apk-and-app-bundle-aab)
12. What is key store file in android? [Explanation](https://stackoverflow.com/questions/6849558/what-is-android-keystore-file-and-what-is-it-used-for)
13. Why we need to sign our app before releasing to PlayStore? [Explanation](https://stackoverflow.com/questions/6849558/what-is-android-keystore-file-and-what-is-it-used-for)
14. What is the use of Gradle in android? [Answer](https://stackoverflow.com/questions/16754643/what-is-gradle-in-android-studio?rq=1)
15. Explain build  flavors in android. [Answer](https://www.journaldev.com/21533/android-build-types-product-flavors)
16. How to implement Dynamic module delivery? [Docs](https://proandroiddev.com/developing-your-own-dynamic-feature-3c48378e3065)
17. Coroutines in android. [Docs](https://blog.mindorks.com/mastering-kotlin-coroutines-in-android-step-by-step-guide)
18. Broadcast receivers in android. [Docs](https://www.journaldev.com/10356/android-broadcastreceiver-example-tutorial)
19. Content providers in android. [Docs](https://www.geeksforgeeks.org/content-providers-in-android-with-example/)
20. What is Intent and it's types? [Blog](https://abhiandroid.com/programming/intent-in-android)
21. Activity and fragment lifecycle. [Check this lifecycle cheat sheet](https://medium.com/androiddevelopers/the-android-lifecycle-cheat-sheet-part-iii-fragments-afc87d4f37fd)
22. What is Job scheduler in android? [Answer](https://www.vogella.com/tutorials/AndroidTaskScheduling/article.html)
23. Explain Alarm manager. [Answer](https://proandroiddev.com/android-alarmmanager-as-deep-as-possible-909bd5b64792).
24. How does MVVM works. [Answer](https://www.journaldev.com/20292/android-mvvm-design-pattern)
25. What is companion object in kotlin? [Answer](https://medium.com/swlh/kotlin-basics-of-companion-objects-a8422c96779b)
26. Difference between val and const in kotlin. [Answer](https://stackoverflow.com/questions/37595936/what-is-the-difference-between-const-and-val#:~:text=Both%20val%20and%20const%20are,val%20for%20run%2Dtime%20constants.)
27. How room works internally? [Answer](https://blog.mindorks.com/how-does-room-work-internally)
28. Explain Hilt in android. [Answer](https://blog.mindorks.com/dagger-hilt-tutorial)

__Additional resources__
[Kotlin cheat sheet 1](https://blog.kotlin-academy.com/kotlin-cheat-sheet-1137588c75a)
[Kotlin cheat sheet and quick reference](https://koenig-media.raywenderlich.com/uploads/2019/11/RW-Kotlin-Cheatsheet-1.1.pdf)
[Android cheat sheet](https://github.com/anitaa1990/Android-Cheat-sheet)

Please do share any interview topics and questions you came across in comments.
Hope this helps :-).