Subsequences recursion

what is wrong in my code
#include
#include
#include
#include
using namespace std;
int x=0;
bool compare(string a,string b){
return a<b;
}

void subsequences(string a,char out [100],int i,int j,string * v){
if(a[i] == ‘\0’){
out[j] = ‘\0’;
v[x++]=out;
cout<<out<<endl;

    return;
}

subsequences(a,out,i+1,j,v);

out[j] = a[i];
subsequences(a,out,i+1,j+1,v);

}

int main(){

string s;
cin>>s;


char out[100];
string v[100];

subsequences(s,out,0,0,v);
sort(v,v+10,compare);

int i=0;
 do{
	 cout<<v[i]<<endl;
	 i++;
 }while(v[i]!="\0");
return 0;

}

hi @kumarakash121005
refer this -->

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.