This Notes is according to the udacity free course :
Android Development for Beginners
The Notes below are my own notes in class.
Lesson 2A : Update a Variable in the App
When you put new variable in the MainActivity.java
you will get a new results when you press the button"+"
USE THE DEBUGGER
H.W.
Some tips : you will find that the number just skip to the quantity of 4. This is not the result we're expected, so we will discuss it in the next note.
Android Development for Beginners
The Notes below are my own notes in class.
Lesson 2A : Update a Variable in the App
When you put new variable in the MainActivity.java
you will get a new results when you press the button"+"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** * This method is called when the order button is clicked. */ | |
public void increment(View view) { | |
int quantity = 1; | |
quantity = 2; | |
quantity = 3; | |
quantity = 4; | |
display(quantity); | |
} |
But in this class you will wonder whether the number just SKIP to the final quantity.
USE THE DEBUGGER
H.W.
Some tips : you will find that the number just skip to the quantity of 4. This is not the result we're expected, so we will discuss it in the next note.
留言
張貼留言