.NET Fiddle

CSharp · Console

/Program.cs

using System;
using System.Collections.Generic;
using System.Linq;

namespace ConsoleApplication1
{
	public class Program
	{
		public static void Main()
		{
			var getOnlyFirst = false;

			var collection = Enumerable
				.Range(1, 100)
				.Select(x => new Item(x));

			var condition = new Func<Item, bool>(x => x.Prop%15 == 0);

			var result = getOnlyFirst
				? new List<Item> {collection.First(condition)}
				: collection
					.Where(condition)
					.ToList();

			foreach (var item in result)
			{
				Console.WriteLine(item.Prop);
			}
		}
	}

	class Item
	{
		public int Prop { get; set; }
		public Item(int prop)
		{
			Prop = prop;
		}
	}
}
;