import { Tuple } from "https://deno.land/x/rimbu@1.0.3/core/main/exports.ts";
const { init } = Tuple;
Returns a Tuple containing all but the last element of the given tuple
.
Examples
Example 1
Example 1
const t = Tuple.of(1, 'a', true)
console.log(Tuple.init(t))
// => [1, 'a']
Parameters
tuple: readonly [...T, unknown]
- the source tuple