Ten kod jest za długi o 80 linii kodu. Upakowałeś cały multum zmiennych o nazwach nie oddających niczego co się dzieje w kodzie. Nie wiem do czego potrzebujesz typów zmiennoprzecinkowych. Masz w kodzie pełno prostych problemów:
prog.cc:11:3: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
c[1]=6;
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:18:6: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
k=c[1];
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:33:13: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
b[0]=b[1];
^ ~
prog.cc:8:3: note: array 'b' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:35:7: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
b[1]=b[0]+d;
^ ~
prog.cc:8:3: note: array 'b' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:37:24: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
if((x>=b[0])&&(x<b[1]))
^ ~
prog.cc:8:3: note: array 'b' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:40:8: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
c[1]=6;
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:50:14: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
f[w]=c[1];
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:86:5: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
c[1]=6;
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:96:11: warning: array index 1 is past the end of the array (which contains 1 element) [-Warray-bounds]
k=c[1];
^ ~
prog.cc:8:3: note: array 'c' declared here
int n,a=1,r,l=0,b[1],m=0,c[1],h=0,g,v[2],x,q,w=0,z=0,j;
^
prog.cc:103:5: warning: variable 'g' is uninitialized when used here [-Wuninitialized]
g++;
^
11 warnings generated.