这段语句哪里错了,运行总报错
#include "stdafx.h"#include<iostream>
using namespace std;
int main(int argc, char *argv[])
{ float sum(float a=8,float b=10,float c=3);
float a,b,c;
cin>>a,b,c;
cout<<sum(a)<<sum(a,b)<<sum(a,b,c)<<endl;
return 0;
}
float sum(float a,float b,float c)
{
return a+b+c;
}
[此贴子已经被作者于2023-3-13 22:06编辑过]