AsyncEnumerable.Range(Int32, Int32) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
產生指定範圍內的整數序列。
public:
static System::Collections::Generic::IAsyncEnumerable<int> ^ Range(int start, int count);
public static System.Collections.Generic.IAsyncEnumerable<int> Range(int start, int count);
static member Range : int * int -> System.Collections.Generic.IAsyncEnumerable<int>
Public Function Range (start As Integer, count As Integer) As IAsyncEnumerable(Of Integer)
參數
- start
- Int32
序列中第一個整數的值。
- count
- Int32
要產生的連續整數數量。
傳回
一個 IAsyncEnumerable<T> 包含一組連續整數。
例外狀況
start
+
count -1 比 大 MaxValue。