Java Class Ex and Hw