#include <iostream>
#include <sstream>
#include <iomanip>
int main() {
// String to number conversion
std::string str_num = "123.456";
std::istringstream iss(str_num);
double number;
iss >> number;
std::cout << "Converted string to number: " << number << std::endl;
// Number to string conversion with formatting
double pi = 3.14159265359;
std::ostringstream oss;
oss << std::fixed << std::setprecision(2) << pi;
std::string str_pi = oss.str();
std::cout << "Converted number to string with 2 decimal places: " << str_pi << std::endl;
return 0;
}