I have a following string:
'0\t36aa, >HWUSI-EAS614_4:1:62:3987:7089:0:1:1... *1\t36aa, >HWUSI-EAS614_4:1:65:3993:10262:0:1:1... at 100.00%2\t36aa, >ILLUMINA-EAS295_5:3:99:4680:15673:0:1:1... at 100.00%3\t36aa, >HWUSI-EAS614_4:1:63:11191:7359:0:1:1... at 94.44%`
I wanna find all pattern between '>' and '...', which are:
HWUSI-EAS614_4:1:62:3987:7089:0:1:1
HWUSI-EAS614_4:1:65:3993:10262:0:1:1
ILLUMINA-EAS295_5:3:99:4680:15673:0:1:1
HWUSI-EAS614_4:1:63:11191:7359:0:1:1
How to write the regular expression, python syntax is preferred.
UUOC
Useless use of redirection also, plus it doesn't do what the OP requested. The answer from @qiyunzhu below will print all the matches.
when I wrote my answer, the question had the string with one ID per line, not all in one line
Okay. It's hard to tell when there have been edits, but that first solution would work then.