title: Converting a float into a string fraction representation
body: <p>In Java, I am trying to find a way to convert a float number into a fraction string. For example:</p>
  
  <pre><code>float num = 1.33333;
  String numStr = Convert(num); // Should return "1 1/3"
  
  float num2 = 1.333;
  String numStr2 = Convert(num2); // Should also return "1 1/3"
  
  float num3 = 0.5;
  String numStr3 = Convert(num3); // Should return "1/2"
  
  float num4 = 2.25;
  String numStr4 = Convert(num4); // Should return "2 1/4"
  </code></pre>
  
  <p>Any ideas how to do this in Java?</p>