Vidyalelo
C++ Programming · Q83

C++ miscellaneous

Programming · C++ Programming · question 83

Q83

What does this template function indicates? ================== template U func(T a, U b) cout<<a<<" "<<b; ==================

A.
A function taking a single generic parameter and returning a generic type which may be different from argument type
Answer
B.
A function taking a single generic parameter and returning a generic type which must be different from argument type
C.
A function taking a single generic parameter and returning a generic type which must have the same type as argument type
D.
A function taking a single generic parameter and returning a specific non-void type

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board