比较笨蛋的方法
记得加结束符号,这一点很重要!!
(WA了不知多少次的痛)
(其实也没有多少但是很痛)
#include#include #include char a[105]; char b[105][105]; int c[105]; int cmp(const void *a,const void *b) { return strcmp((char*)a, (char*)b); } int main() { int t; scanf("%d",&t); while(t--) { int m; scanf("%d",&m); scanf("%s",a); int n=strlen(a);//a字符串长; for(int i=0;i


