namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int max = 0;
int[] shuzu = { 1, 2, 3 };
max = number(shuzu); Console.WriteLine(max);
} public static int number(int[] shu)
{
int max = shu[0];
for (int i = 0; i < shu.Length; i++)
{
if (max < shu[i])
{
max = shu[i];
}
}
return max;
}
}
}
{
class Program
{
static void Main(string[] args)
{
int max = 0;
int[] shuzu = { 1, 2, 3 };
max = number(shuzu); Console.WriteLine(max);
} public static int number(int[] shu)
{
int max = shu[0];
for (int i = 0; i < shu.Length; i++)
{
if (max < shu[i])
{
max = shu[i];
}
}
return max;
}
}
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货