title: Convert fraction to decimal number
body: <p>i'm doing some exercises in my Java book. I'm very new to programming. Therefore, notice (in the code) that i'm still on Chapter one. Now I already did everything, I just want a confirmation if this is legitimate so I can feel free to move on next. </p>
  
  <p>If not, I would sincerely appreciate to <strong>not</strong> do my code for me; I want advice.</p>
  
  <p><strong>Here's the question written in the book</strong>,
  <em>"Write an application that prompts/reads the numerator and denominator of a fraction as integers, then prints the decimal equivalent of the fraction."</em></p>
  
  <p>I'll illustrate this sentence with my code: </p>
  
  <p><strong>I did a revision here. Is this one OK?..</strong></p>
  
  <pre><code>import java.util.*;
  public class ExerciseEleven {
  public static void main (String[] args) {
  Scanner sc = new Scanner (System.in);
  
      double fraction;
      int fractionValue;
      int decimal;
      double value;
  
      System.out.println("Enter Numerator: ");
      int numerator = sc.nextInt();
      System.out.println("Enter Denominator: ");
      int denominator = sc.nextInt();
  
      fraction = (double) numerator / denominator;
      fractionValue = (int) (fraction * 10);
      decimal = fractionValue % 10;
      value = decimal * 0.1;
  
  
      System.out.println(value);
  }
  }
  </code></pre>
  
  <p>It compiles and works fine. 
  Thank you.</p>