Ashish Ramteke wrote: and putting a couple of classes in different packages.
Tushar Goel wrote:I suppose you need to set class path for the same as they are on different path ... .
Stuart A. Burkett wrote:
Do you have any package statements in your classes ? ... .
Campbell Ritchie wrote:… or put all the XXX.java files in the same directory.
Ashish Ramteke wrote:Hi! Thanks you all for the replies- Tushar Goel, Stuart A. Burkett, and, Campbell Ritchie!! . . .
. . . Yes, sir, if the classes are put in one single directory, the programs work fine without any errors. . . . The coding exercise that I was doing told to put the classes in different packages, so, I was trying to access the class from a different package.
Is it necessary to put import statements for accessing classes that are 'public' and in the sub-folder from where the current class is? . . .
Campbell Ritchie wrote:I am assuming you are using the strange name L for your folder.