I have two files, I want to know the starting and ending positions after the matches of the sequences. For example
File_1
VMLLVHYAIIGPGLQAKATREAQKRTAAGIMKNPTVDGITVIDLEPISYD PKFEKQLGQVMLLVLCAGQLLLMRTTWAFCEVLTLATGPILTLWEGNP FWNTTIAVSTANIFRGSYLAGAGLAFSLIKNAQTPRRGTGTTGETLGE KRQLNSLDRKEFEEYKRSGILEVDRTEAKSALKDGSKIKHAVSRGSS RWIVERGMVKPKGKVVDLGCGRGGWSYYMATLKNVTEVKGYTKGGP
File_2
FWNTTIAVSTANIFRGSYLAGAGLAFSLIKNAQTPRRGTGTTGETLGE KRQLNSLDRKEFEEYKRSGILEVDRTEAKSALKDGSKIKHAVSRGSS RWIVERGMVKPKGKVVDLGCGRGGWSYYMATLKNVTEVKGYTKGGP
So, here File_2 starting FWNTTIAVST..... sequences are matching in file_1 at at position 100 and ending YTKGGP at 250. So I want to print this starting and ending position 100-250
Script should be python or perl
Hi, Fin Swimmer, I don't have to idea about the python scripting. If you can write script then it's good for me.. Otherwise please guide this str.index() in perl. I know little bit perl script
For python2: