Musical Theme Time Limit: 1000MS Memory Limit: 30000K Total Submissions: 14874 Accepted: 5118 Description A musical melody is represented as a sequence of N (1<=N<=20000)notes that are integers in the range 1..88, each representing a key on the…
#include<stdio.h> #include<string.h> #include<algorithm> #define maxn 30000 using namespace std; int n; int jilu[maxn]; int wa[maxn],wb[maxn],wv[maxn],ws[maxn],r[maxn],sa[maxn],rankk[maxn],height[maxn];//r数组是将原始字符串进行整数化 int cmp(int *r,in…