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 override static methods?

Answer Posted / yogesh gandhi

Neha,

I didn't get your answer.
You can overload as well as override static methods, but
only with static methods.

I have tried it and it is getting compiled.

Example is here.
*********************************************************
public class abc
{
public static void main(String args[])
{

}
public static void trss()
{

}
public static void trss(int i)
{
}

}
*********************************************************

Is This Answer Correct ?    13 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the main use of java?

1174


How is it possible in java programming for two string objects with identical values not to be equal under the == operator?

1030


Which is the class in java?

1062


Explain when classnotfoundexception will be raised ?

1048


If you are given the name of the function at run time how will you invoke the function?

1139


What is formatted output?

966


What is string data type?

979


Difference between static and dynamic class loading.

1130


What is numel matlab?

1349


What are the legal parameters?

1014


Give the difference between the println method and sqrt method?

1090


When would you use a static class?

990


Why are functions called methods in java?

1008


What are the drawbacks of singleton class?

1011


What is a java list?

1123