• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Package just putting my finger between the teeth

 
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
i've created an package like this.
package pack;
class A
{
void display()
{
System.out.println("Hello");
}
}
/////another file
package pack;
class B
{
public static void main(String as[])
{
A aa=new A();
aa.display();
}
}

the above program is not working,can anyone help me?
------------------
 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ajay
Make sure the "pack" directory is in classpath before running your second program. For more information please visit my page at http://www.javacaps.com/scjp_dac.html#objective2.
Thanks
Konda Balabbigari
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic