1,684 Posted Topics
Re: [QUOTE=Dave Sinkula;366587]Nevermind. Disable color. Remove fonts, and sizes and fonts and colors [again] [[oh, my]]. Then get rid of smilies and indentation, and bulleted listings, and quotes, and code tags, and hyperlinks. And what not. Keep thinning the herd until you've gone too far. Then turn back. I'm leaving now.[/QUOTE] … | |
Re: The distance from the origin, assuming you're using Euclidean distance, is sqrt(x^2 + y^2 + z^2). The dot product? Google it. | |
Re: What's with the color fetish? I'm going to tear into this paragraph as if I wanted to hurt your feelings, because I think it's very bad. [CODE] Cell phones are technologically advancing everyday [b](Duh.)[/b], and they will posses the ability to do many technologically advanced functions [b](You just said this, … | |
Re: You look at the extension of the filename and see what it is. Using programming. And then use if statements to control your behavior based on the extension. | |
Re: I don't know why everyone seems to be giving Narue good reps JUST for making fun of me. All she said is "you fall for a lot of scams and hoaxes, don't you" - basically saying that "you are an idiot for posting this thread." But you were acting loud … | |
Re: Haskell 98: The type system makes it impossible to shoot yourself in the foot. | |
Re: There is no cost to complexity (imo). And the complexity (and technology) is optional. So the answer's yes. | |
Re: What is "capitalist" as a political orientation? Most Democrats and Republicans could not be described as "capitalist". Is "capitalist" a code-word for libertarian? Which option should anarcho-capitalists select? What about people slightly short of anarcho-capitalist and slightly past minarchist? | |
Re: The only way to stop animal cruelty is animal extinction. Anyway, the line of ethics is going to get pretty trippy in the next century. | |
Re: [QUOTE=server_crash]Wow, you people are weird.[/QUOTE] Agreed. 6 feet 3 inches, or 1.905 meters | |
Re: Unsigned is no more optimized than signed; they're the exact same instructions for addition, multiplication, and division. If you really want to optimize numerical code, use Fortran. And before you optimize your code, ask if you really need to optimize anything. And what are you optimizing for? Memory usage? Speed? | |
Re: Relax. You'll do fine. If you feel nervous about the exam, practice writing programs or functions that solve particular problems entirely on paper. Type them into the computer and compile them and see how they fail. Based on your mistakes, take note of what modes of thinking should be avoided. … | |
Re: The easiest way is to make a C++ string and use its concatenation operator (which happens to be the plus operator). Use the c_str method to get the C-style string that's similar to the C++ string you've concatenated that the system function needs. [code]#include <stdlib.h> #include <iostream> #include <string> using … | |
Re: Your get_letter grade function has a space in its name, and the implementation doesn't return anything. | |
Re: Store the array alongside a 'multiplier value' that you multiply the elements of the array by when reading them (and divide by when writing...). Then have MultiplyAll simply change the multiplier value. Also, keep a counter and increment it with every ZeroAll call. Store with each element in the array … | |
Re: 1. The expression "Literal string" is a cute way of writing a memory address that points to to the front of an array of bytes, somewhere, whose contents are "Literal string". Except when initializing an array. 2. Both of those produce equivalent behavior, nyes? 3. Your program doesn't do anything; … | |
Re: Generally speaking, it's whichever algorithm takes the most advantage of hardware. For example, people pretend that bucket sort takes linear time, but it really takes O((n+k) log k) time, where k is the number of distinct elements. They pretend it takes linear time because for values of n and k … | |
Re: The easiest way would be to fork off a call to wget and pipe back its output. | |
Re: - I don't understand the question. - The expression (&T) returns a value of type nodeptr**, when T is of type nodeptr*, but insert expects an argument of type nodeptr*. - Case 10 doesn't change the value of T, so the nodeptr T still points at the same place in … | |
Re: Why? The only thing noobs need to know is how to write in complete sentences and use code tags. A little humility would be nice, too -- some people just expect a free homework service. The last thing we need is people measuring their self-worth based on how many posting … | |
Re: S.O.S. I see it in your screenshot, but I don't see in on my computer. It's not your eyes... But speaking of revelations, rereading the religion thread has been fun. | |
Re: Your string's not null-terminated, unless you're lucky. In Dev-C++, it turns out that a zero was already there at the end of the string 'line'. In VC++'s executable, that turned out not to be the case. You need to use [code]line = new char[length + 1]; strLine.copy(line,length); line[length] = '\0';[/code] … | |
Re: There are two ways to improve your skill and knowledge. One is to learn other interesting programming languages (such as Scheme, Python, Perl, Haskell, or Factor, since this will improve your C++ skill), and the other is to write more programs. The latter is essential, and the former is important. … | |
Re: It seems that you're using an unsigned integer to represent your coordinates. When you decrement an unsigned integer, such as 0, instead of getting -1, you get the highest possible value the integer can represent. In fact, if you're getting 32 thousand, you're probably getting errors related to the comparison … | |
Re: That's a... dun dun dun [i]ONE MEGABYTE FILE!!![/i] That's not relatively small. Especially considering there's no reason not to post a PNG. But wow. I've never seen the reps other people give you. Ha ha ha. As for the topic of killing people, who else do you have on your … | |
Re: This is certainly posted in the wrong room, but that's no sin. You mean that the OS is drawing stuff on your screen at a ninety-degree angle? That is, if you rotated your screen by ninety degrees, it would look normal? This is a feature available for some operating systems … | |
Re: I would guess more of an opposition to the practice of sharing your personal opinion on some particular thing related to another's post, regardless of whether it has to do with the conversation, than political correctness. | |
Re: The only people who've said they're capable of giving out negative rep are moderators, sponsors, etc, so far. | |
Re: I used the secret to hope for a child, and then lo and behold, I found one wandering around in the supermarket! She still hasn't learned to answer to her new name, "Zelda," but I'm working on it. | |
I really like Ruby. Who here has looked at it? What do you think of it? | |
Re: That depends: did the passengers come to a halt too, or did one or more of them fly out the windshield? | |
Re: Maybe [code]int i = p * q << 12; int j = (i >> (sizeof(int)-1) * CHAR_BIT) & (~0xF) i = (i & j) | (~ j);[/code] | |
Re: [QUOTE=tgreer;353812]Negative Reputation appears to be a way for juvenile, immature members without the courage or wit to address someone in public to scrawl anonymous graffiti.[/QUOTE] This is definitely my experience. | |
Re: The function might be located somewhere else in the book. If not, what do you think that function is supposed to do? It looks like it's looking at a string and asking if the user input a valid integer. | |
Re: Here's my rep page now: The top two were for my "Do you like killing people?" question in the yes/no thread ^_^ | |
Re: Don't forget return three; // uses copy constructor some_function(three); // uses copy constructor unless passed by reference Of course, a compiler could behave magically and optimise away a copy constructor call. | |
Re: What do you need help with? Nobody's going to do your homework for you; you need to ask yourself why you can't do this yourself and then figure out specific questions that will help you to solve the problem yourself. If you want somebody to write the whole thing for … | |
Re: Open up synaptic and search for wxwidgets or just 'wx'. By the way, your shift key's broken. | |
It will be a playplace for the children who think that's what the role of this site should be. | |
| |
Re: BEGIN is not a procedure in Scheme; why would it be a procedure in Python? You already have a feature in the language for sequencing expressions with side effects. | |
Re: alloc.h is a nonstandard header file. What are you trying to compile with? | |
Re: You mean using define-syntax? It's in section 7.3 of the R5RS standard. | |
Re: See EBCDIC for an example of a character set that doesn't have consecutive A..Z. | |
Re: That is very nice; thank you for posting it. And thanks for putting it in the code snippets section already. If I may criticize one aspect of your code, your line [inlinecode]if( ( rand() % ++num_nodes ) == 0 ) selected = pn ;[/inlinecode] does a bit too much in … | |
Re: What is this "first-word" function? You haven't said anything about that. It seems to me like you meant to be calling chars->list-of-chars for that... What you need to do is the following strategy: Make a function that does the following: " Hello, world foobar captcha" -> ("Hello" . " world … |
The End.