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...

class test
{
private static void main(String []adsf)
{

}
}

explain me that the above code is error or exception

Answer Posted / xavier

This will throw a runtime error stating main method not public
This is because main method is the starting point of program
execution and it should be accessible by JVM

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Compare Mutex and Semaphore in java.

1006


What is extension method in java?

1043


What is the different types of functions?

1057


Outline the major features of java.

1078


Can variables be used in java without initialization?

1086


What are the actions that can occur when a thread enters blocked state?

1058


Does java initialize arrays to zero?

1035


If I only change the return type, does the method become overloaded?

926


How will you invoke any external process in java?

1117


What is computer compiler?

1001


what is inner class in java?

1135


Where is jre installed?

1044


What if constructor is protected in java?

1125


What are Normalization Rules? Define Normalization?

1055


What is assembly used for?

1021