P2547 [AHOI2004] DNA Mutation

Description

![](https://cdn.luogu.com.cn/upload/pic/1660.png)

Input Format

![](https://cdn.luogu.com.cn/upload/pic/1661.png)

Output Format

Only one line containing a number, representing the total number of "血缘序列对" in the DNA sequence.

Explanation/Hint

Translated by ChatGPT 5