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

What is a template?

Answer Posted / ravinandan

Template is used for generic programming. In other words
when you want to write a function or a class type
independent, go for templates.

template<class T>
void fun(T x, T y); // Is a Template function

template<typename T>
class abc{
T m;
}; // Is a Class Template

template<class T>
class abc{
T m;
}; // Is a Class Template

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are properties in oop?

1025


Is html an oop?

1004


Why do we use class in oops?

916


Why is polymorphism used?

997


What are benefits of oop?

1084


What are the advantages of polymorphism?

979


Are polymorphisms mutations?

1110


is there any choice in opting subjects like 4 out of 7

2131


2. Give the different notations for the class.\

2087


INSTANCE FIELDS DECLARED private ARE ACCESSIBLE BY THE METHODS ONLY.CAN WE CHANGE THE private FIELD OF AN OBJECT IN A METHOD OF SOME OTHER OBJECT OF THE SAME CLASS?

2150


Can bst contain duplicates?

1145


What are different oops concepts?

1004


What is polymorphism what are the different types of polymorphism?

949


How is class defined?

1072


What is abstraction example?

1044