using System.Collections.Generic; using System.Linq; using System.Numerics; namespace Robust.Shared.Toolshed.Commands.Math; [ToolshedCommand] public sealed class SumCommand : ToolshedCommand { [CommandImplementation, TakesPipedTypeAsGeneric] public T Sum([PipedArgument] IEnumerable input) where T : IAdditionOperators => input.Aggregate((x, y) => x + y); }