MCQs>IT & Programming>C++>Output of the following program? template void foo(U&, T&) { std::cout << 'first'; } template void foo(int&, const T&) { std::cout << 'second'; } int main() { int a; double g = 2.; foo(a, g); return 0; }
C++ MCQs
What is the output of the following program? template void foo(U&, T&) { std::cout << "first"; } template void foo(int&, const T&) { std::cout << "second"; } int main() { int a; double g = 2.; foo(a, g); return 0; }
Answer
Correct Answer: first
Explanation:
Note: This Question is unanswered, help us to find answer for this one