var prepareIds=new List<long>(){,};
foreach(var prepareId in prepareIds)
{
Console.WriteLine(prepareIds.IndexOf(prepareId));
}
执行结果如下
0
0
0
var prepareIds=new List<long>(){,};
foreach(var prepareId in prepareIds)
{
Console.WriteLine(prepareIds.IndexOf(prepareId));
}
执行结果如下