Convert prtintf() to cout in C++

Is there a way to convert the following printf() function to cout<< in c++?
printf("Reverse of entered string is \"%s\".\n", str);
std::cout << "Reverse of entered string is " << std::quoted(str) << ".\n" ; // #include <iomanip>

Or
std::cout << "Reverse of entered string is \"" << str << "\".\n" ;
Topic archived. No new replies allowed.