您正在打印功能的地址.
我想你想调用函数并打印它们的返回值.
试试这个
cout << "\nThe surface area of the prism is: " << calculateSurfaceArea(length, width, height) << endl;
cout << "The volume of the prism is: " << calculateVolume(length, width, height) << endl;
Run Code Online (Sandbox Code Playgroud)
代替
cout << "\nThe surface area of the prism is: " << calculateSurfaceArea << endl;
cout << "The volume of the prism is: " << calculateVolume << endl;
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
48 次 |
| 最近记录: |