data-structure-typed/src/types/helpers.ts

12 lines
224 B
TypeScript
Raw Normal View History

export type Comparator<T> = (a: T, b: T) => number;
export type DFSOrderPattern = 'pre' | 'in' | 'post';
export type OneParamCallback<N, D = any> = (node: N) => D;
export enum CP {
lt = 'lt',
eq = 'eq',
gt = 'gt'
}