foo.cpp: In function 'void quicksort(int, int)':
foo.cpp:8:24: error: 'rand' was not declared in this scope
int k=a[left+rand()%(right-left+1)],i,j;
^
foo.cpp:9:6: error: 'i' was not declared in this scope
i=left;j=right;
^
foo.cpp:9:13: error: 'j' was not declared in this scope
i=left;j=right;
^
foo.cpp: In function 'int main()':
foo.cpp:47:19: error: 'system' was not declared in this scope
system("pause");
^
foo.cpp:22:13: warning: unused variable 'j' [-Wunused-variable]
int n,i,j;int x1,x2,y1,y2;int x,y;
^
foo.cpp:38:9: warning: unused variable 'k' [-Wunused-variable]
int k=1,max=0;
^