T Trần Vũ New member Sep 18, 2021 #1 What is the correct syntax of defining function template/template functions? A. template <class T> void(T a){cout<<a;} B. Template <class T> void(T a){cout<<a;} C. template <T> void(T a){cout<<a;} D. Template <T> void(T a){cout<<a;}
What is the correct syntax of defining function template/template functions? A. template <class T> void(T a){cout<<a;} B. Template <class T> void(T a){cout<<a;} C. template <T> void(T a){cout<<a;} D. Template <T> void(T a){cout<<a;}
P Phác Chí Huấn New member Sep 18, 2021 #2 Answer: a Explanation: Starts with keyword template and then <class VAR>, then use VAR as type anywhere in the function below. Upvote 0 Downvote
Answer: a Explanation: Starts with keyword template and then <class VAR>, then use VAR as type anywhere in the function below.