Sunday, July 12, 2009

Oop in c++ code.?

(6) Write a template function that sums two numbers, (passed as parameter) and returns the result. For character type however, the ‘Sum’ function shall display a message “Summation of characters is not supported”.

Oop in c++ code.?
If you have a go at it yourself and there is somewhere where you get stuck or you don't understand then ask again. The idea of homework is to get you to think about the subject.





So study c++ templating and have a go.


No comments:

Post a Comment