using System.Collections.Generic;
using System.Diagnostics;
List<string> strings = new List<string>();
for (int i = 0; i < 10000; i++)
strings.Add($"string {i}");
Stopwatch _stopwatch2 = new Stopwatch();
foreach (var @string in strings)
var count = strings.Count(x => x.StartsWith('1'));
Console.WriteLine(_stopwatch2.ElapsedMilliseconds);
Stopwatch _stopwatch = new Stopwatch();
foreach (var @string in strings)
var count = strings.Where(x => x.StartsWith('1')).Count();
Console.WriteLine(_stopwatch.ElapsedMilliseconds);