int main(){
//using function
int aa;
cout<<"Reversing Texts Using Functions..."<<endl;
system("pause");
cout<<"Number of characters to reverse: ";
cin>>aa;
int bb=aa-1;
char cc[bb];
cout<<"Text to be reversed: ";
cin>>cc;
reverse(aa,bb,cc);
system("pause");
//using function
system("cls");
cout<<"Reversing Texts Without Functions..."<<endl;
system("pause");
//without function
int a;
cout<<"Number of characters to reverse: ";
cin>>a;
int b=a-1;
char c[b];
cout<<"Text to be reversed: ";
cin>>c;
for(int ctr=0;ctr<a;ctr++){
cout<<c[b];
b--;
}
//without function
}