| 1 | Initialize dp[0][0] | (0,0) | N/A | 0 | [[0, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _],
[_, _, _, _, _, _, _, _]] |
| 2 | Initialize first row dp[0][j] | (0,1) | N/A | 1 | [[0, 1, _, _, _, _, _, _], ...] |
| 3 | Initialize first row dp[0][j] | (0,2) | N/A | 2 | [[0, 1, 2, _, _, _, _, _], ...] |
| 4 | Initialize first row dp[0][j] | (0,3) | N/A | 3 | [[0, 1, 2, 3, _, _, _, _], ...] |
| 5 | Initialize first row dp[0][j] | (0,4) | N/A | 4 | [[0, 1, 2, 3, 4, _, _, _], ...] |
| 6 | Initialize first row dp[0][j] | (0,5) | N/A | 5 | [[0, 1, 2, 3, 4, 5, _, _], ...] |
| 7 | Initialize first row dp[0][j] | (0,6) | N/A | 6 | [[0, 1, 2, 3, 4, 5, 6, _], ...] |
| 8 | Initialize first row dp[0][j] | (0,7) | N/A | 7 | [[0, 1, 2, 3, 4, 5, 6, 7], ...] |
| 9 | Initialize first column dp[i][0] | (1,0) | N/A | 1 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, _, _, _, _, _, _, _], ...] |
| 10 | Compare s1[0]='k' and s2[0]='s' | (1,1) | 'k' vs 's' | 1 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, _, _, _, _, _, _], ...] |
| 11 | Compare s1[0]='k' and s2[1]='i' | (1,2) | 'k' vs 'i' | 2 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, _, _, _, _, _], ...] |
| 12 | Compare s1[0]='k' and s2[2]='t' | (1,3) | 'k' vs 't' | 3 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, 3, _, _, _, _], ...] |
| 13 | Compare s1[0]='k' and s2[3]='t' | (1,4) | 'k' vs 't' | 4 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, 3, 4, _, _, _], ...] |
| 14 | Compare s1[0]='k' and s2[4]='i' | (1,5) | 'k' vs 'i' | 5 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, 3, 4, 5, _, _], ...] |
| 15 | Compare s1[0]='k' and s2[5]='n' | (1,6) | 'k' vs 'n' | 6 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, 3, 4, 5, 6, _], ...] |
| 16 | Compare s1[0]='k' and s2[6]='g' | (1,7) | 'k' vs 'g' | 7 | [[0, 1, 2, 3, 4, 5, 6, 7],
[1, 1, 2, 3, 4, 5, 6, 7], ...] |
| 17 | Compare s1[1]='i' and s2[0]='s' | (2,1) | 'i' vs 's' | 2 | ... |
| 18 | Compare s1[1]='i' and s2[1]='i' | (2,2) | 'i' vs 'i' | 1 | ... |
| 19 | Compare s1[1]='i' and s2[2]='t' | (2,3) | 'i' vs 't' | 2 | ... |
| 20 | Compare s1[2]='t' and s2[2]='t' | (3,3) | 't' vs 't' | 1 | ... |
| 21 | Compare s1[5]='n' and s2[5]='n' | (6,6) | 'n' vs 'n' | 1 | ... |
| 22 | Final result dp[6][7] | (6,7) | N/A | 3 | Full dp table filled |
| 23 | Exit | N/A | N/A | N/A | All dp cells computed, minimum edit distance is 3 |