Share via


Vector.Sum<T>(Vector<T>) 方法

定義

傳回指定向量內所有項目的總和。

public:
generic <typename T>
 where T : value class static T Sum(System::Numerics::Vector<T> value);
public:
generic <typename T>
 static T Sum(System::Numerics::Vector<T> value);
public static T Sum<T> (System.Numerics.Vector<T> value) where T : struct;
public static T Sum<T> (System.Numerics.Vector<T> value);
static member Sum : System.Numerics.Vector<'T (requires 'T : struct)> -> 'T (requires 'T : struct)
static member Sum : System.Numerics.Vector<'T> -> 'T
Public Function Sum(Of T As Structure) (value As Vector(Of T)) As T
Public Function Sum(Of T) (value As Vector(Of T)) As T

類型參數

T

要加總之專案的型別。

參數

value
Vector<T>

包含要加總之型別 T 物件的向量。

傳回

T

向量內所有元素的總和。

適用於