Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

can we create a object in static block
class A
{
static {
A a=new A();
}
}

Answer Posted / naresh tuhania

Yes we can do this . Because we can create an object at
runtime and static block is also execute when a class is
loaded by the class loader at runtime

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which types of components are used in designing swing based gui?

929


How is multi-threading gets implemented using swing?

914


What are the different types of layout managers used in swing?

911


What are the swing components?

884


What is the use of java swing?

994


What are swings?

921


What is swing in java javatpoint?

971


What is jpanel in java swing with example?

925


Why does JComponent have add() and remove() methods but Component does not?

943


Write a program to include the internal frame in swing.

944


Why are swing components called lightweight?

923


What is swing in java with example?

931


What is import javax swing?

920


When we should go for codebase in applet?

1017


Is java swing a framework?

975