diff --git a/src/hackerrank/interview_preparation_kit/search/swap_nodes_algo.ts b/src/hackerrank/interview_preparation_kit/search/swap_nodes_algo.ts index 19fd178d..5e4476c9 100644 --- a/src/hackerrank/interview_preparation_kit/search/swap_nodes_algo.ts +++ b/src/hackerrank/interview_preparation_kit/search/swap_nodes_algo.ts @@ -23,7 +23,7 @@ export class Tree { this.buildTree(indexes); } - buildTree(indexes: number[][]): Tree { + buildTree(indexes: number[][]): this { const indexesCopy = [...indexes]; let currentLevel = __INITIAL_LEVEL__;