Hi
I am trying to compile and execute the following piece of code.
package abc;
public class Example
{
Example()
{
System.out.println(" Example class constructor" );
}
public static void main (
String[] args) {
Example newObj = new Example();
System.out.println("Exit main()");
}
}
When i am compiling the code it is getting compiled but when i am executing it i am getting the following error:
Exception in
thread "main" java.lang.NoClassDefFoundError:
NB: I am executing it from the console and is not using any
IDE.