YouSub
Untitled

en English

Untitled English subtitles

0 downloads · 16 lines · added Dec 11, 2015

Report a problem
What's wrong?
Advertisement

English transcript

Hopefully you typed it in all right.
A common mistake is to forget the semicolon at the end of each statement.
Or you may have misspelled the quantity variable in subsequent lines of code.
The variable name must match the same spelling and capitalization
as the very first time that the variable was originally declared.
Also int has to be spelled specifically in this way.
Otherwise java won't recognize that this is supposed to be an integer variable.
For best practice, remember that we always add a space before and
after any operators.
In this case, we only have a sign operator, so
we add a space here and here, in all these cases.
Thanks for making some observations about the code.
There's no right or wrong answer here.
One of the observations you may have made is that int is only used on
the very first line of code, right here, but not on subsequent lines of code.
Let's talk more about that next.

Need subtitles from another video?