R
rh5680
Hi group,
I'm converting a large old C++ program to C#. It has lots and lots and
lots of iostream and strstream io. Is there an equivalent io
capability in C#? Any suggestions on the most efficient way to do
this. Below is a little bit of c++ code I found on the web that shows
what I'm trying to do.
Thanks /Mike
#include <iostream>
#include <strstream>
using namespace std;
int main()
{
char iostr[80];
strstream strio(iostr, sizeof(iostr), ios::in | ios:
ut);
int a, b;
char str[80];
strio << "10 20 testing ";
strio >> a >> b >> str;
cout << a << " " << b << " " << str << endl;
return 0;
}
I'm converting a large old C++ program to C#. It has lots and lots and
lots of iostream and strstream io. Is there an equivalent io
capability in C#? Any suggestions on the most efficient way to do
this. Below is a little bit of c++ code I found on the web that shows
what I'm trying to do.
Thanks /Mike
#include <iostream>
#include <strstream>
using namespace std;
int main()
{
char iostr[80];
strstream strio(iostr, sizeof(iostr), ios::in | ios:
![Blush :o :o](/styles/default/custom/smilies/blush.gif)
int a, b;
char str[80];
strio << "10 20 testing ";
strio >> a >> b >> str;
cout << a << " " << b << " " << str << endl;
return 0;
}