📄 io20_8.03.c
字号:
#include <iostream>
#include <sstream>
#include <string>
/**
** note: no available sstream implementation
** available at this time -- code has not
** been exercised
**
**/
int main()
{
int ival = 1024;
int *pival = &ival;
double dval = 3.14159;
double *pdval = &dval;
// creates a string in which each value is
// is stored separated by a space
ostringstream format_string;
format_string << ival << " "
<< pival << " "
<< dval << " "
<< pdval << endl;
// extracts the stored ascii values,
// placing them in turn in the four objects
istringstream input_istring( format_string.str() );
input_istring >> ival >> pival
>> dval >> pdval;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -