Main.c: In function 'main':
Main.c:20:28: error: subscripted value is neither array nor pointer nor vector
20 | c=a[i];
| ^
In file included from Main.c:2:
Main.c:21:49: error: subscripted value is neither array nor pointer nor vector
21 | if(isalpha(c)&&isdigit(a[i+1]))
| ^
Main.c:21:49: error: subscripted value is neither array nor pointer nor vector
21 | if(isalpha(c)&&isdigit(a[i+1]))
| ^
Main.c:23:48: error: subscripted value is neither array nor pointer nor vector
23 | while(isdigit(a[i+1]))//每组数字逐个数
| ^
Main.c:23:48: error: subscripted value is neither array nor pointer nor vector
23 | while(isdigit(a[i+1]))//每组数字逐个数
| ^
Main.c:25:47: error: subscripted value is neither array nor pointer nor vector
25 | cnt=(a[i+1]-'0')+cnt*10;//多位数
| ^
Main.c:28:35: warning: array subscript has type 'char' [-Wchar-subscripts]
28 | ans+=cnt*W[c];
| ^
Main.c:32:31: warning: array subscript has type 'char' [-Wchar-subscripts]
32 | ans+=W[c];
| ^
Main.c:7:14: warning: unused variable 'a' [-Wunused-variable]
7 | char a,c;
| ^