Q10. Algorithms STL#10
Given the following code snippet :
string s = “bca”;
do {
cout << s << ' ';
} while(next_permutation(s.begin(), s.end()));
cout << s;
What is the output of the given code?
Please explain the output of the 10 questions.
For me, it should be:
-> bca cab cba -> while loop ends --> cba