当前位置: 代码迷 >> 综合 >> 声明数组2
  详细解决方案

声明数组2

热度:46   发布时间:2024-01-17 03:41:20.0
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;namespace ConsoleApplication2
{class Program{static void Main(string[] args){int[] values = new int[5];// 整型变量没有默认值,但整型数组有默认值为0for (int i = 0; i < values.Length; i++ ){Console.WriteLine(values[i]);}Console.ReadKey();}}
}


  相关解决方案