






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!







HW 2 due today (now) HW 3 posted
The public modifier allows any class anywhere to access the variable/method The private modifier only allows access in the class where the variable/method is defined (See: RunSuperDouble.java)
When overloading, Java will still convert types automatically (int to double) But this will only happen if there is not already a match for the current type If the computer cannot decide on the best conversion, the code will not run (See: BadOverload.java)
Whenever you make a Class type (with new) you have used a constructor method For example: Scanner input = new Scanner(System.in); Constructors always have the same method name as the class and are only run (once) when you make a variable of that Class type (See: Constructor.java) Docsity.com