I have two lists:
List<int> positionsThatCannotBeMovedTo =...
List<int> desiredLocations =...
I am trying to remove all of the positions which cannot be moved to from the desired locations to create a list of safe positions:
List<int> safePositions = new List<int>(uniquePositions);
safePositions.RemoveAll(positionsThatCannotBeMovedTo);
however it's throwing the error:
"Argument1: cannot convert from 'System.Collections.Generic.List' to 'System.Predicate'
I'm not entirely sure what this means or how I'm misusing the function. Is anybody able to explain this for me please? I am doing it this way because of the answer in this question: