*****************************************************************
COMPLETE SOURCE CODE FOR : GettingSuperclass.java
*****************************************************************
public class GettingSuperclass
{
public static void main(String[]args)
{
try
{
Class temp=Class.forName("GettingSuperclass");
Class thisIsSuper=temp.getSuperclass();
System.out.println("Superclass for this class is : "+thisIsSuper.getSimpleName());
}
catch(Exception exception)
{
exception.printStackTrace();
}
}
}
*****************************************************************
JUST COMPILE AND EXECUTE IT
*****************************************************************