question: public static Vector formatDecimal ( Collection c , String pattern ) { DecimalFormat f = new DecimalFormat ( pattern ) ; Vector v = new Vector ( ) ; for ( Iterator i = c . iterator ( ) ; i . hasNext ( ) ; ) { Object o = i . next ( ) ; if ( o instanceof Double ) v . add ( f . format ( o ) ) ; else v . add ( o ) ; } return v ; }
target:  Returns a collection of decimals based on the given collection but with the doubles formatted according to the pattern. String values are ignored.