Methods and Pass-by-Value
Java methods: declaring and calling them, signatures, parameters and arguments, pass-by-value, and overloading.
Methods, named blocks of code you write once and call from anywhere, and what a method can and cannot change for the code that calls it. One sentence here is worth the rest: Java passes everything by value, including references, and it makes object behaviour predictable for the first time. It covers declaring a method, reading a signature, parameters and arguments, pass-by-value with two surface-different examples, overloading, and the method whose change the caller never sees. It leaves out variable-length argument lists and recursion.
Contents
10 cardsnot started