1
我必须添加两个int []数组,其中一个mian int []数组在空间上是空的。我想在主数组中添加另一个数组的元素。在Main数组中,会在主数组的最后一个位置添加更多的addtion。添加两个int数组
我有一个数组为 -
var planetNotInRange = new int[7] ;
if(planetSign.Contains(tempFrind))
{
var result = planetSign.Select((b, k) => b.Equals(tempFrind) ? k : -1)
.Where(k => k != -1).ToArray();
// Here I want to add this result Array in to the planetNotInRange array,
// when ever there is some value in the result array.
}
这是在循环将给出数目的整数的阵列组成。现在我想在PLanetInRange Array中一个接一个地连接。
目前尚不清楚你想要做什么。请提供一个具体的例子。 –
我有一个数组为 - var planetNotInRange = new int [7]; var result = planetSign.Select((b,k)=> b.Equals(tempFrind)?k:-1).Where(k => k!= -1).ToArray(); 这是在循环中会给出一些整数数组。 现在我想在PLanetInRange数组中一个接一个地连接。 – Kumar
不要将它添加为注释 - 编辑您的问题的全部细节。 –