I've written code for a few different computers, but so far not the mac.
Lately I've been using:
Visual Studio for C++ on the PC,
CodeWarrior/Freescale for C cross compiled from the PC to a microcontroller, and
Visual C++ 1.52 plus some add-ons for C for an 80386EX embedded system.
None of this code is using iostreams & I have to consider myself weak in that area at the moment. I would have just looked at the responses you got to see what I could pick up, but seeing rtf rather than plain text was a glaring issue for me. In the last week I've had to deal with a couple of mismatched formatting issues.
I'm wondering if there is something else this book is talking about? It says C++. But the code above is exactly what the book put in. Interesting...
I take it you didn't see my post before this one but it seems it works fine in netbeans, but in xcode it wouldn't work. I got the code that I was having trouble with to work perfect in netbeans. What could cause this?
hello, i'm usig this spin control, it works fine, in my application i draw some lines when the spin control increases or decreases an edit box,nice, but when the control change the acceleration it seems like iDelta and iPos (from UDN_DELTAPOS) change their behavior, because in that moment the line plotted is wrong , but after and before that moment all works fine, and the variable shown in the buddy edit box is always well. I guess that in acceleration changes happens somethig that i dont know whith spin control. Any ideas ? i can`t find any good information about how this controls works, specially the acceleration thing.
Are you new around here? It probably is one of these:
- I let others do my homework
- I am troll
- strcat() isn't safe enough; I prefer strcat_s()
Luc Pattyn [Forum Guidelines][Why QA sucks][My Articles] I only read code that is properly formatted, adding PRE tags is the easiest way to obtain that. [The QA section does it automatically now, I hope we soon get it on regular forums as well]
He wants to implement a function where he needs to takes two char* parameters as input at the end it should return a char* by concatenating these two char* values(without using strcat(), strcmp() functions).
required function prototype is
char* concat(const char* c1, const char* c2)
I am unable to solve this one. Please give me the approach
Thanx in advance.....
To invent something, you need a mountain of junk in your mind.
---------------------Thomas alva edison
Note that in what you are doing, you are dealing with 6 variables. You are talking about the 3 char * variables, but as you said, those are pointers. What you must remember is that pointers are pointers - they are used to point to things, in this case arrays of char. These arrays are not automatically provided. You, the programmer, are responsible for providing them for the pointers to point to.
You have to keep in mind the distinction between pointer and "pointee". Once you do that, you would not say that you want to add or concatenate 2 pointers. Instead, you want to concatenate the 2 strings contained in 2 char arrays and put the result in a third char array. You use the pointers to access the char arrays.
That code is too dangerous for words. As long as the length of buf is greater than the combined length of c1 and c2 plus a null terminator it will work. But as soon as the result overflows all hell breaks loose. This maybe OK for a skilled developer such as yourself, but I would not suggest it as a solution for a newbie.