Instantiating an object:

Executing new causes:

  1. Space for the new object to be allocated and default initialized
  2. Any explicit initialization to be performed (such as "private int color = 3;")
  3. A constructor to be called

Rules for constructors:

  1. Method name must exactly match class name
  2. Must not be any return type

Default constructor (no arguments) is created by Java (with empty body) if you write no constructors. This allows you to call new. If you provide a constructor with argument, you loose the default constructor and must write a no-arguments constructor yourself.