5,237 Posted Topics
Re: A " without a matching " A /* without a matching */ A { without a matching } etc etc | |
Re: Personally, I would suggest you learn some alternative approaches. [url]http://en.wikipedia.org/wiki/Windows_Script_Host[/url] Even after 30 years, M$'s idea of a capable command line shell is woeful. The so-called 'extensions' only serve to highlight how truly awful command.com was, and how inadequate cmd.exe remains. Most of your time will be spent working out … | |
Re: Something like [ICODE]FILE.open ("data.txt",ios::app);[/ICODE] So you append, rather than rewrite. Also, opening the file before the loop, then closing it when you're done would help. Your two if statements are always false and true in that for loop. | |
Re: [url]http://www.perl.org/[/url] and a [URL="http://oreilly.com/catalog/9780596000271/"]Camel Book[/URL] First thing you need to search for is all about the array @ARGV | |
Re: Pick a forum - any forum, so long as it's ONE forum. [url]http://forums.devshed.com/c-programming-42/need-help-here-to-explain-this-question-for-me-588311.html[/url] [url]http://cboard.cprogramming.com/showthread.php?t=111855[/url] Better yet, read this [url]http://www.catb.org/~esr/faqs/smart-questions.html#forum[/url] | |
Re: > template<class Elem, class Comp> > MaxHeap<Elem, Comp>::MaxHeap(Elem *h[], int num, int max) { Is this also in your header file? It needs to be, otherwise the compiler can't create the instance of the template which deals with <Voter, SalaryCompare> and then the linker complains about "no such function". | |
Re: You should stop using the register keyword all over the place as well. Modern optimising compilers are far better at figuring out best use of registers, and will just ignore it. So save yourself some typing. | |
Re: > for(B = 1; B < C; B++) Perhaps your code is broken, because C is uninitialised the first time around. Perhaps < A ? | |
Re: [url]http://www.cplusplus.com/reference/stl/stack/[/url] You can implement it however you want (arrays, lists, blah blah) so long as you have "push" and "pop". | |
Re: There's plenty of easy (and not so easy) homework posted on the board. Any of those would make excellent exercises (it's what they're designed for). | |
Re: Well you didn't read this - [url]http://www.daniweb.com/forums/announcement125-3.html[/url] And you didn't say which assembler (nasm,tasm,masm,?asm) you're using. Do you get any error messages perchance? Nor did you say what you want it to do, nor what it does (or doesn't) do instead. | |
Re: How about starting with the basics. Like the program which prompts for value then prints it out. Then add to that program a second variable which allows the program to print out - the current value - the previous value. Believe it or not, after those two steps you're only … | |
Re: You're only going to get true "at the same time" if you've really got a multi-core CPU available. Otherwise, it's just faked by the OS by interleaving both loops very quickly. In the same way that TV is only a rapid sequence of still images, but you perceive the result … | |
Re: Well it's already broken before it's even got 10 lines into the program. > cin>>dataned[i]; Each dataned[i] is an UNINITIALISED pointer. You're busily scribbling data all over other peoples memory. > while(dataned[i]==" ") This is unlikely to be ever true (pure luck basically), so the loop only happens once (if … | |
Re: First thing it needs before anyone would want to look at it, is some of this. [url]http://en.wikipedia.org/wiki/Indent_style[/url] | |
Re: Get a real job which is essentially your "hobby" at the moment. Pay really close attention to everything which is going on around you. Fixing a couple of PCs in your garage for a few friends for cash in hand is one thing. Being sued by an irate customer because … | |
![]() | Re: I could tell you to go read the manual page for printf to find the ACTUAL conversion for printing a double. Note that printf and scanf are NOT perfectly symmetrical with their use of conversion formats. %lf for printf is meaningless. |
Re: Even by this boards relaxed standards, your English sucks. [url]http://www.catb.org/~esr/faqs/smart-questions.html#writewell[/url] Did someone remove half the keys from your keyboard or something? | |
Re: > Beyond that it's the same old basic arithmetic that you learned in the first grade. Do they still teach that? Apparently not [url]http://www.literacytrust.org.uk/Database/businessupdate.html[/url] [quote] The CBI surveyed more than 500 companies with 1.1million employees. They found that 52% of employers are dissatisfied with the basic literacy of school leavers … | |
Re: Same questions, same answers [url]http://cboard.cprogramming.com/showthread.php?t=111787[/url] Stop wasting so much of other peoples brain-power on your RTFM questions. It's fine, if one forum doesn't deliver an answer in a few days, then move on to try your luck somewhere else. But concurrent posting is spamming, and is a proxy for [url]http://www.catb.org/~esr/faqs/smart-questions.html#urgent[/url] | |
[url]http://nambulous.wordpress.com/2008/08/23/remove-the-net-framework-assistant-10-from-firefox/[/url] Why do I need it? Why didn't you ask me? - I agreed to your necessary maintenance of your OS, not for you to modify any 3rd party applications which happen to be on the machine to suit your purposes (put that in your EULA). Why is "Uninstall" disabled? | |
Re: You just described one way - what's the problem? | |
Re: Who knows, that's for the implementation to decide. - in release mode, it's typically back in the heap untouched. - in debug mode, it could be filled with some specific pattern to mark "deleted data", and perhaps held in a "pending" list for a while. Specifically to assist with spotting … | |
Re: ALL your template functions in the cpp file need to be in the .h file. When you instance a template with a type, the compiler needs all the template code to generate the appropriate type-specific instances of those functions. | |
Re: Judging from the way the code colouring goes completely out of whack at about line 20, I'd say that you're missing a " on a previous line to end a string. | |
Re: Because strcmp() is C. You're already half-way there with line 9, so just carry on using == to compare two std::string variables. | |
Re: > I am using few asm files based on x86 instruction set. Why? If you did this for "performance reasons" on a PC, what makes you think the app will even run on a mobile platform, which is usually well behind the curve in terms of current processor performance. Rewrite … | |
Re: Not entirely. gcc (which I guess you're using) has some built-in functions (as evidenced by the second message). First, turn these off to get a better idea of what's going on. [ICODE]gcc -fno-builtin malloc.c[/ICODE] This done, the compiler should be then forced to follow the normal C sematics for undeclared … | |
Re: Start with the basics. Read some input, and print it right back out. Then think about modifying it to detect a palindrome. | |
Re: It's not that you can't, it's just that it'll be so much harder to do, and you'll still only end up with something like 640x480 in 256 colours. Which is enough to make the output of any digital camera look, well pretty crappy. Your choice. | |
Re: > Currently I'm doing two degrees parallely (physical & IT). So you tried to eat an elephant in one go, and now it's stuck in your throat. What do you want us to do about it? Do you want to swallow or cough it out? IT is way too intensive … | |
Re: Sure, which bit exactly are you having problems with? - reading into an array - adding values - playing it | |
Re: Which operating system? Which compiler? Which .... There's no standard way to find out, nor is there much use that you can make of it even when you know it. | |
Re: 1. Learn how to indent code. 2. Learn how to use a debugger. The debugger would trap the segfault, AND then allow you to explore the code at the point the trap happened. From that you might get more of an idea as to where it's going wrong than simply … | |
Re: W.getHours()[B][COLOR="Red"];[/COLOR][/B] Look closely.... | |
Re: Whenever you create a new node, you need to make sure new_node->next is NULL. | |
Re: [code] 3DFilter: filter.o $(IO)file_io.o $(CC) $(CFLAGS) -o 3Dfilter filter.o $(IO)file_io.o $(CFLAGSPOST) filter.o: filter.c $(IO)file_io.h includes.h $(CC) -c $(CFLAGS) filter.c file_io.o: $(IO)file_io.c $(IO)file_io.h includes.h $(CC) -c $(CFLAGS) $(IO)file_io.c [/code] Everything except the executable needs -c (compile only) The executable needs all the libraries. | |
Re: So are you in control of either the producer or consumer, source code wise? Is the producer a perl script? | |
Re: Depends on the scale of the problem. If you can "see" the whole problem at once, then just doing the code is probably fine. But if it's going to take you more than a day (or you plan on maintaining it in any way), then some kind of design is … | |
Re: Instead of relying on a syscall to output a string, is there one to output a character? If so, use that to practice using a loop to scan a string until a \0 is found. Then you can make the loop do other things, like say compare a char with … | |
Re: Try [URL="http://cboard.cprogramming.com/showthread.php?t=111666"]cross-posting[/URL]. Try posting your source code. | |
Re: @ianvdl Are you a teacher / lecturer / TA of this course? > qualifies as poor academic practice If you're pushing "gets()" and "fflush(stdin)" as being the height of "academic excellence" then expect a rough time round these parts. | |
Re: So if this were a pack of cards, player1 would choose a card, and the others would be dealt a card from the remaining deck. Think of it in these terms, - shuffle the deck - find card (and remove it) - deal card (from the top of the deck, … | |
Re: Decimal 123 123 / 10 is 12 123 % 10 is 3 Now replace /N and %N with a base of your choice, rinse and repeat. | |
Re: [url]http://lmgtfy.com/?q=Apriori+Algorithm+implementation+in+C[/url] | |
Re: Install a decent firewall which allows you to control who gets out, as well as who gets in. Configure it to only allow your browser to make outbound connections over http. Install [url]http://www.wireshark.org/[/url] and use it to observe what your machine is doing on the network. | |
Re: Look at past posts, and work out the probability that on any given day, there'll be a new post from some wannabe graduate who can't think for themselves, and who needs "help thinking of a project". D'ya think this line will work with say - I can't think of what … |
The End.