Once I scan the last "X" and next coming "X" 's distance is less than or equal to 3 letters, I will replace those letter between the last "X" and next coming "X" with "X"
Thanks for any advice.
Hi bartus11,
Thanks for your perl command.
Do you have any idea if my input data is shown as below:
>Read_1
XXXXXXXXXXSDFXXXXXDS (condition 1: After the last "X" per line, if the distance is less than or equal to 3 letter, replace those not "X" letter with "X")
TREXXXXXXXSDFXXXXXDS (condition 2: Before the first "X" per line, if the distance is less than or equal to 3 letter, replace those not "X" letter with "X")
.
.