我是编写 lambda 表达式的新手,我遇到了下一个问题:我有
List<int> lifeField;
I want to find index of those members, that correspond to next condition:
(((number % (10 * currentMove)) == 1) || ((number % (10 * currentMove)) == 2))
where number is member of List and currentMove is integer - 0,1,2
例如:
if it is first move
currentMove = 0
I search number 1 or 2
if it is second move
I search numbers 11,21
......我想在这里找到如何用 lambda.... 或其他函数写这个
int indexOfLife = Array.FindIndex(lifeField, ?????????);