A
avilella
Hi,
I am looking for an elegant way to do the union of two string. For
example:
$seq1 = "--- --- GAA --- GGA";
$seq2 = "AAC TGG --- --- ---";
The rule is to do the union of the letters, leaving the dash symbol
when both have a dash in a given position:
$union = "AAC TGG GAA --- GGA";
Anyone? Maybe using a regular expression?
Thanks,
Albert.
I am looking for an elegant way to do the union of two string. For
example:
$seq1 = "--- --- GAA --- GGA";
$seq2 = "AAC TGG --- --- ---";
The rule is to do the union of the letters, leaving the dash symbol
when both have a dash in a given position:
$union = "AAC TGG GAA --- GGA";
Anyone? Maybe using a regular expression?
Thanks,
Albert.