O'Reilly logo
  • Dirgni Yordania Mayen thinks this is interesting:

  • Therefore, only line 8 will compile because it uses public access.
  • From

    Cover of OCA: Oracle Certified Associate Java SE 8 Programmer I Study Guide: Exam 1Z0-808

    Note

    But if line 6 doesn't compile, then we cannot use an instance that hasn't been created.