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

why constructor dont have returns type?

Answer Posted / sankar r k

The function of the constructor is to assign values to the
instance variable when the object is created for the first
time.The name of the constructor and the class name will be
same.

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by platform independence? What is an interface?

1035


what is the purpose of using rmisecuritymanager in rmi?

972


Can a private method of a superclass be declared within a subclass?

1041


How is a variable stored in memory?

1010


What is the difference between menuitem and checkboxmenu item?

1340


Can we declare the main method of our class as private?

1005


What is the purpose of declaring a variable as final?

972


What does replaceall do in java?

916


How to instantiate static nested classes in java?

1089


How do you compare values in java?

1030


What is difference between overloading and overriding in java?

1027


How many types of assembly languages are there?

972


Is string is a class in java?

967


Is constructor inherited?

964


what is server side caching?

2174