In a recent podcast, David Blatner and Anne Marie Concepcion, proprietors of the excellent InDesignSecrets blog, talked about how InDesign's "Balance Ragged Lines" feature works. They discussed how the feature tends to favor a longer first line and a shorter second line, but that "under the hood" InDesign has the code to balance the lines differently.
I've whipped up a script that "exposes" this functionality in InDesign CS3/CS4. With this script you can tell InDesign to favor a shorter first line and a longer second line, or to try to make all lines the same length. See the documentation and example files that are packaged with the script for more detailed information.