java algorithim help

Discussion in 'Programming' started by goldviper98, Apr 11, 2012.

  1. goldviper98

    goldviper98 New Member

    Joined:
    Apr 11, 2012
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    public class Dieroller {

    public static void main(string[]args);

    public int die1;
    public int die2;
    public int die3;
    public int die4;

    Roll();

    public void Roll() {

    Die1 = (int)(math.random()*6 + 1;
    Die2 = (int)(math.random()*6 + 1;
    Die3 = (int)(math.random()*6 + 1;
    Die4 = (int)(math.random()*6 + 1;
    String word = "good roll";

    while (dieNum > 0) {
    word = "good roll";
    }

    System.out.println(die1 + " ");
    System.out.println(die1 + " ");
    System.out.println(die1 + " ");
    System.out.println(die1 + " ");
    }
    }//end class Dieroller
    is what i have atm i need help on how to fix it and run it and if i am missing anything i am new to java so dont makefun because i probabally make a big mistake
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice