>:</strong>  A closure that accepts an <code>inout</code> state and returns the
  next element of the sequence.
<strong>Returns:</strong> A sequence that yields each successive value from <code>next</code>.</p>

    <h4>Declaration</h4>    
    <code class="language-swift">func sequence&lt;T, State&gt;(state: State, next: @escaping (inout State) -&gt; T?) -&gt; UnfoldSequence&lt;T, State&gt;</code>
    
    
</div></div>
</div>
