17 lines
259 B
C#
17 lines
259 B
C#
|
|
|
|
|
|
|
|
using System;
|
|
using System.Collections.Generic;
|
|
|
|
public static class Enumerables
|
|
{
|
|
public static void ForEach<T>(this IEnumerable<T> @this, Action<T> action)
|
|
{
|
|
foreach (T item in @this)
|
|
{
|
|
action(item);
|
|
}
|
|
}
|
|
} |