2.3 Instantiation
Introduction
Instantiation is the process of creating an object from a class using the `new` keyword. `new` allocates memory for the object's fields, runs a constructor to initialize them, and returns a reference to the newly created object, which is typically stored in a variable.
Key Concepts
Java Syntax
Code Examples
`b = a` makes `b` point to the same object as `a`. Changing `b.name` therefore also changes what `a.name` reports, since there is only one Student object.