>obislavu
A good solution for your problem is to use a...
Yes I had originally said that I would not do this the way that I did it, except that this approach relied on the general approach of the questioner. (Context sensitive, or something).
I'm familiar with a variety of approaches here. You...
Okay, I built some code that does what you say (however, I'm assuming that you want the input converted to binary int values, hence the sscanf conversion, cf. below).
Note, I would not do this this way, I would use C++ STL containers for this. I particularly don't like the container methodology...
Phew. I looked at this somewhat, and find it very confusing. I find both the code and the statement of requirements confusing.
If you can be somewhat more specific, I will try to help.
As far as the requirements go, are you looking for an array of characters that contain text representations...
You don't want an OR, you want a LOR (logical or). A LOR will OR each bit into the result. Really a different thing from OR.
Very simple example:
unsigned long a = 2; // i.e. 0010
unsigned long b = 1; // i.e. 0001
unsigned long d = 4; // i.e. 0100
unsigned long result;
result = a | b; //...
Hmm. I'm inviting myself to discuss the previous post, which appears as a response to an earlier post of mine. I have to infer a little, since there are no comments.
I think that there are three undesirable aspects to the adjustments that this last post made (I actually made my post to correct...
I'm not sure that the PATH environmental variable will work with all compilers (e.g. SUN FORTE).
Most compliers provide a compiler command line switch that lets you add directories to the 'include search list'.
Usually (YMMV) this is of the form:
-I<directory name> lets you specify...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.