javaCertificate Q. ------------------- Which of the following statements are true? [Check all correct answers] 1. Local classes can access final variables and final parameters of the enclosing method and non-final member variables of the outer class. 2. A constructor cannot be defined for a anonymous class. 3. An instance of a static nested class can be created without an instance of its enclosing class. 4. None of the above. Answers: 1,2,3. I did not choose 1, because I thought the statement suggests that local classes can ONLY access non-final member variables of the outer class. Does anyone else have that problem? Thanks. [ November 06, 2003: Message edited by: Cathy Song ]
Cathy In my opinion, I don't think there's any problem with the question. Option 1 doesn't say ONLY, so I would say it's an unfair assumption. If I say "I have a cat", you can't assume that cat is the ONLY pet I have Cheers Harwinder