title: Conversion between feet and meters
body: <pre><code>public static void main(String[] args) {
      Scanner input = new Scanner(System.in);
      System.out.println("This program converts between feet and meters");
      System.out.printf("%5s%12s%6s%12s%12s\n","Feet","Meters","|","Meters","Feet");
      System.out.println("                                                    ");
  
      for(double f = 1.0, m = 20; f &lt;= 10.0; f++, m += 5.0){
          System.out.printf("%5.1f%12.3f%6s%12,1f%12.3f\n", f, footToMeter(f), "|", m, meterToFoot(m));
      }
  
  }
  public static double footToMeter(double foot){
      return foot * 0.3048;
  }
  public static double meterToFoot(double meter){
      return meter / 0.3048;
  }
  </code></pre>
  
  <p>Results should be like:</p>
  
  <pre><code>Feet Meters | Meters Feet
  1.0  0.305  | 20.0   65.574
  2.0  0.610  | 25.0   81.967
  </code></pre>
  
  <p>But instead I get the following Exception:</p>
  
  <pre><code>Exception in thread "main" java.util.UnknownFormatConversionException: Conversion = '1'
  at java.util.Formatter.checkText(Formatter.java:2503)
  at java.util.Formatter.parse(Formatter.java:2467)
  at java.util.Formatter.format(Formatter.java:2414)
  at java.io.PrintStream.format(PrintStream.java:920)
  at java.io.PrintStream.printf(PrintStream.java:821)
  at Ex6_9.main(Ex6_9.java:15)
  </code></pre>