Carey Brown

Bartender
+ Follow
since Nov 19, 2001
Merit badge: grant badges
Forum Moderator
Carey Brown currently moderates these forums:
For More
Colorado, USA
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Carey Brown

Bhaskar Bantupalli wrote:
Wouldn't (5/8) resolve to 0?


Yes, assuming the formula was written for a computer and not a human. Considering that the formula was pertaining to a computing parameter that would make sense. But if that were the case then it should have been written as (5.0/8.0), On the other hand it makes no sense to present a formula where part of the expression equates to zero, so, no.
2 days ago
Read the thread. The problem was not with the Dialog.
3 days ago
You might want to consider first writing a thorough regression test for the existing code that you can later use to test your new code. In that way you can be confidant you haven't broken anything. Alternatively, could you set up a framework that allowed both pieces of code to be run in parallel so that the outputs could  be compared.
5 days ago
1 week ago
With indent and BOOLEAN.
1 week ago
The hasNext() is returning false. This is my work around.
2 weeks ago
What jar file are you building with?
2 weeks ago
A Swing program made cleaner by using the 'GBC' wrapper class.
2 weeks ago
A wrapper class to simplify Swing coding using GridBagConstraints. See the various 'set' methods.
2 weeks ago

Mike Simmons wrote:

Campbell Ritchie wrote:Does it really use <=?


It also says "searching backwards". It does make sense in comparison to indexOf(), I think, even if it's not what we want in this problem.


When it said "from" index I was picturing a left to right search which is not what it was doing. I guess I had only used the from-index along with indexOF() in which case I  would have been correct.
3 weeks ago
I don't see where you're calling Searcher.binarySearch().
3 weeks ago
Method always returns an empty string.

This had me scratching my head yesterday because the code seemed so obvious. I had to read the Javadoc twice before catching a subtlety in its wording.
3 weeks ago
You need to show us the code that is trying to call your method..
3 weeks ago
In general, a comparator that always returns the same value will not change the order of the data. There are some sorting algorithms where this is not the case but I don't believe that  Java's implementations use those.
3 weeks ago