aspose file tools*
The moose likes Beginning Java and the fly likes Java Radix Sort Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Java Radix Sort" Watch "Java Radix Sort" New topic
Author

Java Radix Sort

george harvin
Greenhorn

Joined: May 01, 2013
Posts: 1
I am down to the end of the semester and running out of time for a lot of things. One last assignment I have to do for my java class is modify a prewritten radix sort for integers so that it will radix sort strings instead. I really am at quite a loss on what to do here and it isn't terribly important that I actually learn much from this assignment as we are already at the end of the class and we will not be tested on the content covered in this assignment. Is there anyone that would mind taking a look at the code provided and helping me out? I would rather not post all of the code here for obvious reasons. Thanks for your time.
Jeff Verdegan
Bartender

Joined: Jan 03, 2004
Posts: 6109
    
    6

Welcome to the Ranch!

It's worth noting that this site is about learning, not about passing classes. People won't do your work for you. If you want help, post the relevant code, or an SSCCE equivalent, and ask a specific question.
Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 7807
    
  21

george harvin wrote:One last assignment I have to do for my java class is modify a prewritten radix sort for integers so that it will radix sort strings instead. I really am at quite a loss on what to do here and it isn't terribly important that I actually learn much from this assignment as we are already at the end of the class and we will not be tested on the content covered in this assignment. Is there anyone that would mind taking a look at the code provided and helping me out? I would rather not post all of the code here for obvious reasons. Thanks for your time.

As Jeff said.

I will, however, offer this advice: If the original radix sort was sorting based on 'digits' (ie, base 10), then a String radix sort is likely to be based around characters (ie, base 65536). If your code basically does that, chances are it's probably right. Furthermore, the business of extracting a 'digit' is already provided for you.

Remember: in Java, a char is a numeric type.

Winston

Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java Radix Sort