using System; using System.Linq; public class Test { public static void Main() { byte[] large = new byte[100]; for (byte i = 0; i < 100; i++) { large[i] = i; } byte[] small = new byte[] { 23, 24, 25 }; var res = Enumerable .Range(0, large.Length-1) .Cast() .FirstOrDefault(n => large.Skip(n.Value).Take(small.Length).SequenceEqual(small)); Console.WriteLine(res); } }