Re: Help writing Java programme?
My only suggestion would be to convert the rationals to floating point numbers. for example:
1/2 = .5.
Then, you can put the decimal values in the array, sort them, and then convert the numbers back to the rational form when outputting. The array class has a method called sort() so you can check out the java api from the link above and play with that method to get it to do what you want. Alternatively, you may be able to store the rationals as strings, and not worry about the conversion. Just use an Integer.parseInt(rationalNumber); type setup and store the result in the array.
**Official Self-proclaimed glorified excessive (insert additional adjectives here) post editor/modifier.
Edit = Best feature ever