t;1&gt;&gt;
                                                    //     }&gt;&gt;
                                                    //   }&gt;&gt;
                                                    // }&gt;
</code></pre>
<h2>Reverse Elements</h2>
<p>The following uses Script to reverse elements within a Tuple.</p>
<pre><code class="language-typescript">const Reverse = Type.Script(`&lt;List, Result extends unknown[] = []&gt; = (
  List extends [infer Head, ...infer Tail extends unknown[]]
    ? Reverse&lt;