1
delegate bool Number(int n);
public class Program
{
public static void Main(string[] args)
{
Number n = new Number(set);
number.setNo(n);
}
public static bool set(int x)
{
if (x == 5)
{
return true;
}
else return false;
}
}
public class number
{
public static void setNo(Number r, int num = 5)
{
if (r(num))
{
Console.WriteLine("Value Match");
}
else
{
Console.WriteLine("Value NotMatch");
}
Console.ReadLine();
}
}
}
非常にありがとうございます:) – danu