Android SDK emulator with INT declarations are fun!

For the last few days, I have been working on a cool Java program to incorporate OnClick Java code:

Button ShowfactButton = (Button) findViewById(R.id.Showfactbutton);
View.OnClickListener listener = new View.OnClickListener()

With this java code, we are using the SDK auto-fill feature to activate View.OnClickListener Java code which initialized the ShowfactButton in the app.

In the { } section of the code for this public void section of the code, I set up the function with declaration of ‘int’:

int randomNumber = randomGenerator.nextInt(3);

…so with each action of the button on the Android SDK Emulator as if using the touch screen of the real phone, the numbers 0,1,2 appear in sequence.

My Andriod SDK emulator is actually set to emulate a Nexus 5 (1080 x 1920, 4.95″) with target Android 4.4.2 API Level 19.