/in/foo.cc: In function 'long long int ch(int)':
/in/foo.cc:9:10: warning: array subscript has type 'char' [-Wchar-subscripts]
--s[a[w]];
^
/in/foo.cc: In function 'int main()':
/in/foo.cc:22:17: warning: format '%s' expects argument of type 'char*', but argument 2 has type 'char (*)[60]' [-Wformat=]
scanf("%s",&a+1);
^
/in/foo.cc:25:31: warning: array subscript has type 'char' [-Wchar-subscripts]
for(int i=1;i<=n;++i)++s[a[i]];
^
/in/foo.cc:26:35: warning: array subscript has type 'char' [-Wchar-subscripts]
for(int i=1;i<=n;++i)ans+=(d[a[i]]-s[a[i]])*ch(i);
^
/in/foo.cc:26:43: warning: array subscript has type 'char' [-Wchar-subscripts]
for(int i=1;i<=n;++i)ans+=(d[a[i]]-s[a[i]])*ch(i);
^