/// <summary> /// Creates a new parallel query that returns the number of elements in a sequence. /// </summary> /// <typeparam name="TSource">The type of the elements of source.</typeparam> /// <param name="query">A query whose elements will be count.</param> /// <returns>A parallel query that returns the number of elements in the input sequence.</returns> public static IParallelQueryExpr <int> Count <TSource>(this IParallelQueryExpr <IEnumerable <TSource> > query) { return(new ParallelQueryExpr <int>(QExpr.NewCount(query.Expr))); }