aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes access control Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "access control" Watch "access control" New topic
Author

access control

aruna ver
Greenhorn

Joined: Jun 24, 2002
Posts: 8
hi
in the following code
package f1;
public class F1{}
package f2;
public class F2 extends F1{}

the ans given was
3) The code for F1 will compile but the code for F2 will not compile
why connot F2 see the class F1
i think F1 is public so it should be accessble even it is in differnt package
can any body help me out here
thanks
Leandro Oliveira
Ranch Hand

Joined: Nov 07, 2002
Posts: 298
i think there should be an import statement!!!
::::
import f1.F1
Sarma Lolla
Ranch Hand

Joined: Oct 21, 2002
Posts: 203

i think there should be an import statement!!!
::::
import f1.F1

Please observe the missing semicolon at the end of import statement.
It should be import f1.F1;
Jasper Vader
Ranch Hand

Joined: Jan 10, 2003
Posts: 284
picky, picky Sarma!
but the exam requires attention to detail like that!


giddee up
 
 
subject: access control