When I run the code or app in my Google Pixel 3 smartphone, the code works fine for two input commands and the app terminates straight after.
There is a button for random dice generator and an input box for users to type numbers between 1-6. If they guess the number that matches the random dice generator, their point is incremented by one.
int countPoints = Integer.parseInt(points.getText().toString());//converts the textview into an integer object
int addPoints = countPoints + 1;//increment the points by 1
The app or code runs for two inputs of the user then closes down. The app is run on my Google pixel 3. When I get rid of the code above, the app does not close down and works fine. This code should initially work.