Search:
Type: Posts; User: henryswanson
Search:
Search took 0.03 seconds.
-
March 15th, 2012, 07:43 PM
I'm trying to write an MD5 generator (for integrity checks, not actual hashing), but it doesn't seem to be working right. And it only operates on a 512-bit chunk, for now. Hashing the empty string...
-
June 20th, 2011, 04:51 PM
Alright, I'll go check that out. Thanks!
-
June 19th, 2011, 07:08 PM
I'm planning on making a game which multiple people can play over a network. I've never done any programming involving a network, so I have lots of questions.
1) Do I need a third-party library to...
-
I have, but I can't find a pattern that would work. The problem seems to be that infoboxes, tags, and pictures show up before the real body of the text, and I can't figure out how to tell if a link...
-
After reading the latest xkcd: http://xkcd.com/903/ I started writing a program that will find the first link on each article, and see if it does eventually lead to philosophy. However, I know next...
-
Oh, right. I keep forgetting about the debug version not being as fast as release. That really sped it up. And yeah, next_permutation() does work. Thanks!
-
I've tried using that, but it's far too slow. I think that might be because it produces things in a strict order. Also, it produces n! more permutations than I need, and since n is going to be around...
-
I'm trying to make sets of n k-sided dice, using each number from 1 to n*k once. n and k are known at compile time. So, I thought of making an array with ints recording which die the number belongs...
-
April 29th, 2011, 09:27 PM
I'm writing an application which has to know when the user has clicked on a curve that is shown on the screen. I can get a copy of the curve, and the point the user has clicked, but I don't know how...
-
April 24th, 2011, 06:05 PM
Yeah, just giving a solution doesn't help. If that solution is explained, that'd be a lot better. On the other hand, you just have to hope they'll read it. :P So, here goes.
The for loop is what...
-
April 8th, 2011, 09:27 AM
Alright. I suppose I can just ignore the problem, and hope the user won't be bothered by it. :P
-
April 7th, 2011, 03:47 PM
When I attempt to rescale a JFrame, which has no listeners, and has two JPanels in it, the layout takes a bit to resize itself. It's not slowness due to long calculations, since there's nothing that...
-
March 31st, 2011, 08:26 PM
Also, if you want exactly k spaces, not k-or-fewer, you could use a recursive method. I know nothing about its efficiency though. It would go something like this:
public static void main(String[]...
-
March 31st, 2011, 05:22 PM
Whoops, sorry about that. Too bad there's no printfln(). Also, could he call println() once after each printf()? Or is that slower/less readable than getting the newline separator?
-
March 29th, 2011, 05:17 PM
Alright, I've rewritten a few parts of it, and it is working (at least on my computer). I'll put in comments to show why I changed it.
#include <iostream>
using namespace std;
void...
-
March 29th, 2011, 04:35 PM
Are you trying to have multiple player names and multiple scores? One name and many scores? Also, you have ( ` ) around your \n, where you need ( ' ).
-
March 29th, 2011, 04:29 PM
So, have an abstract method for initializing the fields?
-
March 28th, 2011, 09:59 PM
For the formatting, use System.out.printf("Here is some text with a value %.2f and some more text.\n", value). The % means that a value will be inserted into the text. The .2 means to format two...
-
March 28th, 2011, 09:34 PM
Is there a way to specify in a base class that the derived class must create a constructor with certain parameters? Kind of like an abstract method, but it appears to be forbidden to create an...
-
March 28th, 2011, 09:15 PM
Alright, I went back and looked at the example I saw, and the third comment was not above a method or variable, but above another comment. It went like this:
public class Matrix {
/**...
-
March 28th, 2011, 09:11 PM
Is the Yearly Income Tax correct? I think there is an issue in the if-else statements. You have 5 ranges, 0-6000, 6000-25000, 25000-75000, and 75000-150000. For one, you need a 150000+ range. But...
-
March 28th, 2011, 09:01 PM
Well, what errors are you getting? When you check if the user entered 'q', you need to use ==, not =. = is assignment, not equals. == is equals. Also, this wasn't much of an issue since the code was...
-
March 28th, 2011, 06:16 PM
Well, a is a pointer to the first element in the list, right? So a-1 is one before the beginning of the list, and garbage is stored there. I think you mean *(a+x), which would give the last element...
-
March 24th, 2011, 12:42 PM
-
March 23rd, 2011, 08:27 PM
I'm confused as to the purpose of three javadoc comments.
/**
* What's this for?
*/
package group.subgroup
import some.stuff;
|
Click Here to Expand Forum to Full Width
|