namespace Canon.Tests.Utils;
public static class EnumerableExtensions
{
///
/// 含有索引的遍历
///
/// 可遍历的接口
///
///
public static IEnumerable<(T, uint)> WithIndex(this IEnumerable enumerable)
{
return enumerable.Select((value, index) => (value, (uint)index));
}
}