C# 新表达式需要()

C# 新表达式需要(),c#,C#,我遵循一些微软教程,得到了这样的代码,但它不工作 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApp1 { class Program { static void Main(string[] args) {

我遵循一些微软教程,得到了这样的代码,但它不工作

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] liczby = new int liczby[] { 5, 6, 7, 8 ,9, 10 };

            Console.WriteLine(liczby[5]);

            Console.ReadKey();
        }
    }
}

将实例化int数组的行更改为:

int[] liczby = new int[] { 5, 6, 7, 8 ,9, 10 };
这只是一个语法错误

int[] liczby = new int liczby[] { 5, 6, 7, 8 ,9, 10 };
此行有语法错误,替换为:

int[] liczby = new int[] { 5, 6, 7, 8 ,9, 10 };

几乎:
int[]liczby=newint[]{5,6,7,8,9,10}“它不工作”并不能描述它正在做什么。如果你有错误,告诉我们是什么。否则,告诉我们它在做什么,你并不期待。