ArrayExtensions.For<T>
Extension Method in ArrayExtensions
Declaration
public static void For<T>(this T[] array, Action<(T element, int index)> action)
Description
Invokes an action for each element in the array. The element and index are passed as parameters.
Type Parameters
T | The type of the array. |
Parameters
array | The array to iterate over. |
action | The action to invoke. |