LinkedList<T>.FindLast(T) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
尋找包含指定值的最後一個節點。
public:
System::Collections::Generic::LinkedListNode<T> ^ FindLast(T value);
public System.Collections.Generic.LinkedListNode<T> FindLast(T value);
public System.Collections.Generic.LinkedListNode<T>? FindLast(T value);
member this.FindLast : 'T -> System.Collections.Generic.LinkedListNode<'T>
Public Function FindLast (value As T) As LinkedListNode(Of T)
參數
- value
- T
該值在 中定位 LinkedList<T>。
傳回
最後一個 LinkedListNode<T> 包含指定值的(若找到);否則,為 null。
範例
關於包含此方法的範例,請參見該 LinkedList<T> 類別。
備註
從 LinkedList<T> 開始 Last 並從 開始,從 開始,直到 First,向後搜尋。
此方法執行線性搜尋;因此,此方法是一個 O(n) 運算,其中 n 為 Count。