|
-
Dec 9th, 2001, 08:00 AM
#7
Monday Morning Lunatic
Originally posted by Amon Ra
basivcally, can i put 2 strings together with "&" ? without using strcat?
If you're using C++ strings, then you can use the + operator.
Bear in mind that it won't do type conversion to strings for you, you need to define your own operators if you want that (or use a stringstream):
Code:
#include <sstream>
using namespace std;
string somecode() {
ostringstream oss;
int y = 5;
oss << "Hello " << y;
return oss.str();
}
As for ObjPtr, yep. & is the address-of operator, and its counterpart is the * dereferencing operator.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|