以下代码导致C3867(…函数调用缺少参数列表…)和C3350(…委托构造函数需要2个参数…).我究竟做错了什么?
public ref class Form1 : public System::Windows::Forms::Form
{
public:
bool IsEven(int i){
return (i % 2) == 0;
}
Form1(void)
{
numbers = gcnew array<int>{
1,2,3,4,5,6,7,8,9,10
};
array<int> ^even = Array::FindAll(
numbers,gcnew Predicate<int>(IsEven));
}
};

