Error description:
If we are editing A="ALGORITHM" to B="ALTRUISTIC", insertion would mean to insert a char at A[i] to match B[j], and the insertion edit distance should be Edit(i, j - 1) + 1; similarly deletion edit distance should be Edit(i - 1, j) + 1
Chapter number or note title: Dynamic Programming
Page number: 110
Error description: If we are editing
A="ALGORITHM"
toB="ALTRUISTIC"
, insertion would mean to insert a char at A[i] to match B[j], and the insertion edit distance should beEdit(i, j - 1) + 1
; similarly deletion edit distance should beEdit(i - 1, j) + 1
Suggested fix (if any): swap the expressions