Compiler output
prog.cpp: In function 'int rec(int, int, a, a)':
prog.cpp:15:9: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if(cur >= s.length())return ans;
^
prog.cpp:16:21: warning: array subscript has type 'char' [-Wchar-subscripts]
a next = poz[s[cur]];
^
prog.cpp: In function 'int main()':
prog.cpp:27:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].x = 1;
^
prog.cpp:28:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].y = i;
^
prog.cpp:33:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].x = 2;
^
prog.cpp:34:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].y = i;
^
prog.cpp:39:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].x = 3;
^
prog.cpp:40:11: warning: array subscript has type 'char' [-Wchar-subscripts]
poz[s[o]].y = i;
^