int culsum(initializer_list i1)
{
int sum = 0;
for (const auto &elem : i1)
sum += elem;
return sum;
}
错误: 未定义标识符 “initializer_list”
int culsum(initializer_list i1)
{
int sum = 0;
for (const auto &elem : i1)
sum += elem;
return sum;
}
错误: 未定义标识符 “initializer_list”