It gaves some garbade value for code provided by you

#include<bits/stdc++.h>
using namespace std;

int main() {
string s;
cin>>s;

int a[s.length()];
int k = 1;
for(int i=s.length()-1;i>=0;i--){
	int place = s[i]-'0' - 1;
	// cout<<place<<endl;
	a[place] = k++;
}

for(int i=s.length()-1;i>=0;i--)cout<<a[i];
return 0;

}
this the code that you have provided me
sir i want to know where i am wrong in my code that i have provided you yestreday


@rathidevesh906_1dcc73a061c159bb this is passing all test cases maybe u were providing wrong input…

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.