{"id":"duplication-cost-free-when-implementations-correct","text":"Per-problem code duplication (TreeNode definitions, tree builders, test helpers) carries zero maintenance cost as long as every copy is correct — there is no shared module to fix once, but there is also nothing to break.","truth_value":"IN","source":"","source_url":"","source_hash":"","justifications":[{"type":"SL","antecedents":["duplication-over-shared-infrastructure","self-contained-solution-with-local-treenode"],"outlist":["build-helper-uses-list-pop-zero"],"label":"duplication is free precisely until a copy contains a bug — the O(n) list.pop(0) in the tree builder is duplicated across every tree problem, so fixing it requires N edits instead of one, turning zero-coupling into a liability"}],"dependents":["zero-coupling-cost-invisible-at-runtime"],"metadata":{"last_reviewed":"2026-06-07T22:02:22","review_result":"pass"},"created_at":"","updated_at":"","reviewed_at":"","verified_at":"","retracted_at":"","explanation":{"steps":[{"node":"duplication-cost-free-when-implementations-correct","truth_value":"IN","reason":"SL justification valid","antecedents":["duplication-over-shared-infrastructure","self-contained-solution-with-local-treenode"],"label":"duplication is free precisely until a copy contains a bug — the O(n) list.pop(0) in the tree builder is duplicated across every tree problem, so fixing it requires N edits instead of one, turning zero-coupling into a liability","outlist":["build-helper-uses-list-pop-zero"]},{"node":"duplication-over-shared-infrastructure","truth_value":"IN","reason":"SL justification valid","antecedents":["treenode-is-de-facto-shared-via-inline-copies","tree-serialization-helpers-duplicated","per-problem-data-structure-isolation","repo-no-cross-problem-imports"],"label":"Architecture deliberately prioritizes isolation over deduplication"},{"node":"treenode-is-de-facto-shared-via-inline-copies","truth_value":"IN","reason":"premise"},{"node":"tree-serialization-helpers-duplicated","truth_value":"IN","reason":"premise"},{"node":"per-problem-data-structure-isolation","truth_value":"IN","reason":"premise"},{"node":"repo-no-cross-problem-imports","truth_value":"IN","reason":"premise"},{"node":"self-contained-solution-with-local-treenode","truth_value":"IN","reason":"premise"}]}}