5,237 Posted Topics
Re: > Why and can I do anything for removing? Try using 0 if you want to fetch the message PEEK implies look at the message, but DON'T remove it. You got what you asked for. The other problem is, having filled your buffer with \0, if recv() also fills the … | |
Re: So what 'port' is your robot plugged into? - Serial - Parallel - USB > My question is ,is it really addres or i am wrong informed All x86 processors have a large amount of memory address space (where your program runs from), and 64K of I/O space (where all … | |
Re: > on these results few teachers said it is the problem of compilers. No, it's a problem with the teachers not knowing the language rules well enough. For C and C++, multiple side effects on the same variable has ALWAYS BEEN UNDEFINED. What does that mean, it means the compiler … | |
Re: Using a C compiler to compile C++ code. The compiler driver will correctly invoke the correct compiler, but will fail to add on the correct libraries. What command other than 'cc' should you use? | |
Re: Boolean operators evaluate to 0 (false) or 1 (true). So depending on the outcome of that, you have z = 2 * x + (0); z = 2 * x + (1); | |
Re: 1. Write it in C 2. Compile with "gcc -S prog.c" 3. Inspect prog.s to find out how the compiler does it. 4. Figure out how you should have passed the ADDRESS of input and returnkey to the function. 5. Does .word really reserve the same space as an int … | |
Re: It's quite rare to see a first-time poster use code tags correctly. It's rarer still to expect the code to be indented in any meaningful way. | |
Re: The programmer (ie YOU) had better start with the reading of the forum rules, and putting forth some demonstration of effort which is more than simply copy/pasting the assignment with a horrid colour scheme. > phase1(due xx/11/07), Lemme guess, this is already passed, or tomorrow. I'm also going to guess … | |
Re: Perl is good. PHP might be better. | |
Re: Does it involve maintaining a separate temporary list of 'n' nodes? Keep it in English please, not cryptic SMS speak [url]http://www.catb.org/~esr/faqs/smart-questions.html#writewell[/url] | |
Re: > also, just a note you can do this to store up to n charictors in a row. Simple char arrays are no match for a C++ string in a C++ program. | |
Re: Create a small test program which just calculates the sine of 180 degrees, and show us that it doesn't print 0 as a result. Then post that WHOLE program (not random snippets where you think the problem is), then perhaps we can explain what is really going on and what … | |
Re: Do you have an example of what you're trying to do? Since you said "swap without a temp", perhaps you're referring to this dumb trick? [url]http://c-faq.com/expr/xorswapexpr.html[/url] | |
Re: > while ( !input.eof( ) ) Well on the iteration before this becomes true, value is going to get a garbage value (most likely), which is going to completely screw up your attempt at a calculation. Never use eof() to control a loop, that's not what it's for. [icode]while ( … | |
Re: Post the code which - creates nodes - adds them to the list - prints the list. There's nothing strange when it's implemented correctly, so I'm just going with there are bugs in your code. | |
Re: I agree - close and forget about it. | |
Re: > mainmenu(); // return to caller No it doesn't, it calls it once more. So eventually, you end up with mainmenu calls income_menu calls mainmenu calls income_menu calls mainmenu calls income_menu calls and so on. Keep going long enough, and you'd run out of stack. If you want to get … | |
Re: How about posting some real examples we can look at rather than you just saying "it doesn't work". | |
Re: xmas is just a marketing scam to make up for what would otherwise be a terrible time for selling anything to anybody. There's always a profit to be made from the prophet. | |
Re: 1. Why are you still messing about with such an old compiler? 2. Why (oh WHY) are you trying to write assembler in your C programs. What lesson are you meant to be learning, futility? | |
Re: Probably (ie, due to your crappy indentation) because the case is OUTSIDE the switch. This is good. All the cases and braces line up, and you can instantly tell the structure of the code simply from following the indentation. [code] switch ( foo ) { case 1: switch ( bar … | |
Re: Well which operating system / assembler / tools are you using at present? A debugger needs to be pretty well matched to what you have in order to work effectively. | |
Re: > How many bools can I connect?? As many as you like > How many bools [B]SHOULD [/B]you connect? Usually a lot less. One set of && and one set of || is about the limit of what would be easy to understand and test for. If you were being … | |
[url]http://news.bbc.co.uk/1/hi/uk_politics/7104115.stm[/url] This isn't the only incident of it's kind either in the recent past. And these are the same muppets who are trying to push an all encompassing ID card on the UK population. In the time between it being hacked, and the govt finally giving up on the "it's … | |
Re: If you're using a POSIX system (like Linux), then you also need to read up on fork() and wait(). In pseudocode [code] if ( fork() == 0 ) { execl() } else { wait() } [/code] | |
Re: > In the above code does the line 6 (return 0), There are 3 standard values [ICODE]0 - which means success EXIT_SUCCESS - which also means success EXIT_FAILURE - which mean it didn't succeed.[/ICODE] You can also return any other value (in an implementation defined manner), though almost every system … | |
Re: Actually, reading the forum rules and taking care to make sure that your post is presented in the best light (and not just dumped because you're in a hurry) is a good idea. [url]http://www.daniweb.com/forums/announcement125-3.html[/url] | |
Re: > I have no idea what the problem is. And I gave up caring about the "me me me" attitude of the OP with the constant bumping, and the not reading the forum rules, or caring enough to format the code. Too much effort, too little reward. | |
Re: How about you learn to read to begin with? Lets say, the forum rules. Or how to post code using code tags Or maybe even the watermark at the back of the edit window. Or (gasp, shock, horror) using the preview post feature to make sure what you spewed forth … | |
Re: <vader> I sense a disturbance in the ethernet, a sense that the same question has been asked [URL="http://cboard.cprogramming.com/showthread.php?t=96027"]elsewhere[/URL] </vader> | |
Re: [url]http://www.go4expert.com/forums/showthread.php?t=7558[/url] [url]http://cboard.cprogramming.com/showthread.php?t=96279[/url] Spamming multiple forums with your question seldom has the effect that you desire. | |
Re: Woo Hoo! Your score is 0 on a scale of 1 to 10. You hate Bush with a writhing passion. You think he is an idiot, a liar, and a warmonger who has been an utterly incompetent, miserable failure of a president. Nothing would give you greater pleasure than seeing … | |
Re: Smooth - in order to prove your point, you resurrected this dead thread :icon_rolleyes: > Just cause you cant see something doesnt mean it isnt there I can't see your garden from here, but if you were to tell me that there is some green grass there, then I would … | |
Re: Yeah, then they ask you to "register" when you get right to the end so they can spam you with other rubbish. | |
Re: Well if they're not going to breed, they're biologically irrelevant. So why not reduce the carbon footprint even further and commit suicide NOW and then the rest of the planet doesn't have to put up with all that self-righteous whining. In other words, why not apply the "no children" rule … | |
Re: Sure, you first read the documentation which describes your processor and how to decode an instruction (say 0x24FF) into an actual instruction (say move r0, r1). The rest is just rinse and repeat. | |
Re: Focus on what "isBackground" rather than everything else. If it's background, replace with corresponding pixel from background image, otherwise just copy the pixel. | |
Re: Well in degree terms 360 / 1 = 360, and the sin of this is 0 360 / 2 = 180, and the sin of this is 0 as well. 360 / n is always going to be between 0 and 180, and sin over this range is always positive. … | |
Re: I prefer [URL="http://cboard.cprogramming.com/showpost.php?p=691408&postcount=4"]number 5[/URL] | |
Re: Meh, you've pre-empted my reportage... "properly named" :icon_confused: When did the leet-speek-kiddie language become proper? True, that's pretty much the sentiment of the poster - oh well, back to sleep I suppose. | |
Re: [URL]http://www.daniweb.com/techtalkforums/thread59835.html[/URL] First an OS, and now a game. [quote=Tauren] I guess I am going to give up its not really worth it I dont know how the hell to do sdk I only understand c++ I will not waist my time learning how to do Some stupid ass thing like … | |
Re: You have to wonder with so many "bullets" being fired at them how they manage to still get to the forum and still make a complete mess of it. If they get an infraction (and a PM), they should [B]not be allowed to post[/B] until they've read the PM and … | |
Re: It is also a terrible use of assert(). Assert is for checking program logic errors, like this [code] double mySqrt ( double x ) { assert( x >= 0 ); // no negatives please } [/code] The default action of assert is to kill the program stone dead. Your user … | |
Re: Yes, leave the ; out of the macro definition. Then things like [ICODE] if ( EVENT_RESIZE(event) == SUCCESS )[/ICODE] also work as well. | |
Re: > char *temp = new char[2]; char temp[2]; would have worked as well, plus it has the advantage of not being a memory leak. | |
Re: Are you dumber than a box of rocks? Do none of these comments mean anything to you? Last edited by Ancient Dragon : 1 Day Ago at 03:19. Reason: add code tags Last edited by Ancient Dragon : 1 Day Ago at 04:53. Reason: add code tags Last edited by … | |
Re: So what's wrong with say - storing a variable number of values in a vector - scanning that vector for the largest value, using a for loop |
The End.