223 B10 lines
Blame
1export interface TreeData {
2 parentById: Record<string, string>;
3 childrenById: Record<string, string[]>;
4}
5export declare const findCommonAncestor: (
6 id1: string,
7 id2: string,
8 { parentById }: TreeData
9) => string;
10