The previous chapter introduced us to the fundamentals of our programming tool, such as IDEs and virtual machines, and allowed us to create a Hello World app. This second chapter is fundamental because you will learn everything about Android activities and Android life cycles, which are mandatory to create Android apps. At the end of this chapter, we will have a solid understanding of how Android apps are born and their life and death. Moreover, mastering the concepts exposed by this chapter will result in better stability and avoid crashes and resource bloat, while a poor understanding can even introduce OS instability.
In this chapter, we will cover the following recipes: