|
Algorithm 2 Correct two consecutive deletion symbols |
-
Input:
.
-
Output:
.
-
1:
.
-
2:
Get the binary sequence and the run-length vector of .
-
3:
Get the total number of elements of as .
-
4:
= .
-
5:
Set .
-
6:
if
then
-
7:
while do
-
8:
if mod then
-
9:
if then
-
10:
;
-
11:
= del_correct2+
-
12:
else
-
13:
-
14:
end if
-
15:
else
-
16:
if then
-
17:
;
-
18:
= del_correct2+
-
19:
else
-
20:
-
21:
end if
-
22:
end if
-
23:
end while
-
24:
else
-
25:
while do
-
26:
if mod then
-
27:
if then
-
28:
;
-
29:
= del_correct2+
-
30:
else
-
31:
-
32:
end if
-
33:
else
-
34:
if then
-
35:
;
-
36:
= del_correct2+
-
37:
else
-
38:
-
39:
end if
-
40:
end if
-
41:
end while
-
42:
end if
|