A simple solution like this should work for you:
String[] vars = {"1.22","230.08","34.11"};
List<Float> newlist = new ArrayList<Float>();
for (String s : vars) {
newlist.add(Float.valueOf(s)); // converts your string to float
}
Collections.sort(newlist);
The Collections.sort() will sort your list in place (returns void, so don't try to assign it to a new variable there). At this point the newlist contains Floats. With the new information from your comment below, you'd like them changed back into Strings. You can do that with another loop:
List<String> numsAsStrings = new ArrayList<String>();
for (Float f : newlist) {
numsAsStrings.add(f.toString());
}
If you want to then turn the List back into an array like the one you started with you can use the toArray method from the Collection interface:
vars = numsAsStrings.toArray(new String[0]);
I would suggest trying this "default" search and seeing if it's fast enough for your needs. It's often surprising how fast it can sort things. Only after trying the built-in and getting an idea for speed would I look to another algorithm. To do otherwise is premature optimization.
As you can see by all of the new additions, what started as a simple solution turned into a lot of code (looping through it twice in addition to whatever the sort() method is doing internally). And while this solution is pretty easy to follow even for beginners, I'd have to recommend using the Comparator approach that Ted Hopp suggested, and choosing his answer as the correct one. It will be less code to read for the next person that has to look at your code (my only suggestion would be to name the Comparator for what it does like "stringAsFloatComparator")
Comparators are useful, powerful, elegant things. I would recommend reading up the Comparator section of the Java tutorial if you are unfamiliar with them.
int/longarray?