Can someone tell me what is wrong with this C++ function definition please?
Code:void Test1 ( int m, int n) { return 3*m+n; }
This is a discussion on error in function definition within the C++ Programming forums, part of the General Programming Boards category; Can someone tell me what is wrong with this C++ function definition please? Code: void Test1 ( int m, int ...
Can someone tell me what is wrong with this C++ function definition please?
Code:void Test1 ( int m, int n) { return 3*m+n; }
Your return type is wrong.
Code:int Test1 ( int m, int n) //Note the "int" { return 3*m+n; }