title: How do I have a random int from 1 to 6 using math.random() in java?
body: <p>I'm writing a method in java which relates to a die throw and I try to use the math.random() but i realized that 0 is included in the random integers involved. Additionally, I don't quite get the *7 part what does it mean?</p>
  
  <p>I went to research from the Java API but it doesn't mention any bit about this or is it I am doing the wrong research? Thanks so much for reading!</p>
  
  <pre><code>public int dieThrow()
  {
      int num = (int)(Math.random() *7); //returns an integer 
      return num;
  }
  </code></pre>