5,237 Posted Topics
Re: Well it looks for all the world like your temp isn't pointing anywhere. A crude fix might be to make temp an array of char, rather than just a pointer to char. Better, use std::string for all your strings. | |
Re: > I write my thesis in Artificial Intelligent fields. Perhaps create an AI system which can auto-respond to all the "please think for me" posts we seem to get on this forum. | |
Re: In a loop which runs 12 times, you want [code=c++] cin >> temps[0][col]; // this is max cin >> temps[1][col]; // this is min [/code] | |
Re: [url]http://www.nondot.org/~sabre/os/articles[/url] | |
Re: Sure, figuring out how to use code tags would be high on your list. You were a lot closer than most people manage, but you still didn't make it. | |
Re: You're not going to believe this, but there's this new fangled invention called [URL="http://clusty.com/search?query=approximate+square+root+algorithm&sourceid=Mozilla-search"]"Da Interweb"[/URL] which has useful tools like "Search Engines". Take a trip to [URL="http://www.catb.org/~esr/faqs/smart-questions.html#before"]here[/URL] as well, then read the rest of the ASQ (for that is what it is). | |
Re: Maybe upgrade to a compiler which matches your OS, rather than cling to the backward compatibility ? Lets begin with which option you chose? Or perhaps add some error detection to the initgraph() call. [url]http://www.cs.colorado.edu/~main/cs1300/doc/bgi/initgraph.html[/url] | |
Re: > Also is this code correct? I am getting strange errors... Whilst saying that they're "strange" errors is a step up on "I'm getting errors", it really doesn't help us that much to figure out what's going on. Be specific, post actual error messages and actual observations. | |
Re: The short answer is you can't. The language itself is portable, therefore it works hard to avoid any explicit knowledge of the OS on which it is running. Take TurboC (an often used, but misplaced example), and your OS is XP. Is your OS a) DOS b) The Virtual DOS … | |
Re: > but I don't know the order. Then you'll have to read the documentation to find out. You can't just look at 2 bytes and decide which order they're supposed to be in. When you have found out, it will be one of [icode]result = ( x1 << 8 ) … | |
Re: So what's the problem? Have you read the relevant documentation to learn about the .cap file format? Are you able to open and read the file, and retrieve a packet? Are you able to decode the header of that packet to determine it's purpose? | |
Re: How about the other "incentive" of working out which people are worth helping? If two posters have started 100 threads (say), where one of them has marked nearly all of them as "solved", and the other hasn't even bothered, then I'd like to know. | |
Re: So why didn't you put the comments in when you wrote it? Also, how come you missed all the hints to use [code][/code] tags when posting code. | |
Re: [url]http://www.daniweb.com/forums/thread99986.html[/url] [url]http://www.daniweb.com/forums/thread99863.html[/url] [url]http://www.daniweb.com/forums/thread99867.html[/url] Guess what all these threads have in common? Yes, that's right, they've all been " Last edited by moderator : 1 Day Ago at 01:46. Reason: Added CODE tags" | |
Re: > t = num / 10; If num is 1234, then t is 123 This is WAY beyond the end of your array. | |
Re: 1. main returns an int, not void. 2. None of your strings have a \0 at the end, so things like printf with %s, and atol are going to be disappointed. 3. a = atol(&string1[cnt]); I rather suspect you want just the digit value, in which case it would be … | |
Re: [url]http://www.tek-tips.com/viewthread.cfm?qid=1433688&page=1[/url] | |
Re: > would you be able to make me a basic program with an array that times > 2 numbers from the array and shows it to the user Why can't you create one, to explore the problem for yourself. If you can get it to work, you might be able … | |
Re: Which OS/Compiler do you have ? Where is the printer connected to your PC, serial, parallel, USB, network? You say printf, are we to assume some kind of console program? | |
Re: Perhaps a structure, say [code] struct question { std::string question; std::string answers[4]; int correctAnswer; }; [/code] Then later, you can say [icode]question quiz[10]; // 10 questions in this quiz[/icode] Now see if you can write some code to - initialise that array, say from a file - print each question … | |
Re: When you realise all such expressions are undefined, you can relax and get some sleep. [url]http://c-faq.com/expr/index.html[/url] > But when i am assiging the result of that expressiion in any variable then i got 0 value That's one of the hallmarks of undefined behaviour, change anything at all and the result … | |
Re: Do a google search for "shunting yard algorithm". ![]() | |
Re: > You must hand in your work by the 10th of December 2007 to the Undergraduate Office. Please post the email address of your assessor so that we can be sure of timely delivery of the assignment to the correct place. | |
Re: [url]http://www.catb.org/~esr/faqs/smart-questions.html#urgent[/url] Then read the rest of the [URL="http://www.catb.org/~esr/faqs/smart-questions.html"]ASQ[/URL] | |
Re: Well there's this - [url]http://www.daniweb.com/forums/announcement118-3.html[/url] So that people might care enough to look at your code rather than just dismissing it as an unreadable mess. | |
Re: Did you see this thread at the top of the forum? [url]http://www.daniweb.com/forums/announcement118-3.html[/url] Did you see the watermark at the back of the edit window? | |
Re: Gee, yet another massive post from someone too dim to figure out how to use code tags despite the numerous places where they get explained!. Good luck with that, I'm sure people will be only too glad to wade through several hundred lines of unformatted code for a fossil compiler … | |
Re: When you say "image", you're referring to a copy of all the sectors of information stored in the memory card right? And not reciting the tale of someone told to make a copy of the floppy disk by putting it on the photocopier :) | |
Re: [URL="http://cboard.cprogramming.com/showthread.php?t=96671"]How many more I wonder?[/URL] | |
Re: > Any Idea for a project in Web Aplications? Well you could write a detector for useless bumps of dead threads on forums. It seems the world is full of students incapable of independent thought. | |
Re: Use a string stream to create a filename, like so. [code] #include <iostream> #include <fstream> #include <sstream> using namespace std; int main() { ostringstream fname; int T = 22; fname << "results.xls_" << T << ".xls"; cout << fname.str() << endl; ofstream outfile(fname.str().c_str()); outfile.close(); return 0; } [/code] | |
Re: So do you have a mywindow.cpp which implements the rest of the functionality of your class in mywindow.h ? | |
Re: Yeah, and this thread was 3 years old before assorted "chippies" came along with their "me too" responses. | |
Re: Our normal definition of "help" is that you make an effort to produce some code, then we help you with whatever it is you're stuck on. Your definition of "help" seems to be you post your assignment and then wait for someone else to do the work. Read the intro … | |
Re: Look up pthread_exit() and pthread_join() for ways of communicating information from the thread back to the parent. | |
Re: > Should I use structures? Yes, it's certainly a lot more convenient than using lots of arrays. | |
Re: Have you considered storing all your init data in an XML file instead? There are libraries to support XML, and plenty of tools to deal with XML. | |
Re: [url]http://clusty.com/search?query=PCB+cleaner[/url] The first thing I would suggest you do is carefully remove the HD and put it in a really safe place, or find a similar machine to plug the HD into so you can get some backups done. Observing correct [URL="http://en.wikipedia.org/wiki/Electrostatic_discharge"]ESD[/URL] precautions whilst working would be paramount to avoid … | |
Re: > this is urgently needed I'm sure it is, but that isn't my problem. [url]http://www.catb.org/~esr/faqs/smart-questions.html#urgent[/url] Nor am I interested in people in too big a hurry to read the forum rules, and completely ignore the copious references to USE CODE TAGS all over the forum. | |
Re: > if (current == NULL) // in loadSymbol 1. current can never be NULL at this point in the code, given that it's the first thing after the inverse test in the while loop. 2. It's a good job anyway, because the code inside the if() would dereference a NULL … | |
Re: Gah, more cross-forum [URL="http://www.go4expert.com/forums/showthread.php?t=7711"]posting[/URL] :icon_mad: | |
Re: This should help you with your parallel port programming. [url]http://www.lvr.com/parport.htm[/url] | |
Re: Don't start multiple [URL="http://www.daniweb.com/forums/thread99594.html"]threads[/URL] on essentially the same topic. | |
Re: Whenever you have an array, you need to be thinking about using a for loop as well. | |
Re: [url]http://www.daniweb.com/forums/announcement118-3.html[/url] | |
Re: So what have you managed to achieve so far (apart from not reading the introductory threads at the top of the forum). We're here to help, not give you answers right off the bat. | |
Re: Answered here - [url]http://cboard.cprogramming.com/showthread.php?t=96575[/url] [url]http://www.catb.org/~esr/faqs/smart-questions.html#forum[/url] | |
Re: So what you really want to start with is something simple like "isMemberOf". A union is merely a membership test to see if the item is in either list. An intersection is a membership test to see if the item is in both lists. How much of the list functionality … |
The End.