In JAVA we can close the application. We trying to develop skills with Kotlin and feel we are using the correct syntax to close the application. The issue is that the code o
Grendel here is the absolute easiest two ways to close the Kotlin App the first way will open the app on PageTwo when it is reloaded not elegant but I included on the chance that someone has a Splash Screen
moveTaskToBack(true);
exitProcess(-1)
The second way is so simple and old you are going to scream It will close the Kotlin App and when reloaded the MainActivity is shown first
finishAffinity()
I tested this with Nexus 9 API 26 I do not have a Samsung Galaxy S2 but feel free to mail me one ha ha