Summary
In this chapter, we learned how to use if
, else
, and switch
to make decisions with expressions and branch our code. We saw and practiced while
, for
, and do while
to repeat parts of our code. Then we put it all together in two quick demo apps.
In the next chapter, we will take a much closer look at Java methods, which is where all our code will go.