// Use Double Wrapper class to print out decimal with 2 places import java.io.*; public class wrapperDriver2 {public static input in = new input(); public static void printWith2Decimals(double n) {Double nu = new Double(n); String s = nu.toString(); int place = s.indexOf("."); // decimal automatically has at least .0 s = s + "00"; // in case not enough spaces s = s.substring(0,place+3); System.out.println(s); } public static void main(String[] args) throws IOException {double n; System.out.print("Enter a number "); n = in.getDouble(); printWith2Decimals(n); System.out.println(); }}