Search:

Type: Posts; User: Charlie

Search: Search took 0.23 seconds.

  1. Replies
    7
    Views
    3,727

    [SOLVED] Re: I thought that this would be right?

    Did you actually swap the > for a <?
  2. Replies
    7
    Views
    3,727

    [SOLVED] Re: I thought that this would be right?

    public int doubleEachDay(double jackpot) {
    double amount = 0.01;
    int numDays = 0;

    while(amount > jackpot){ <-- amount < jackpot, "is less than"
    amount=(amount*2);
    numDays++;
    ...
  3. Replies
    7
    Views
    3,727

    [SOLVED] Re: I thought that this would be right?

    If thats all the code you have in your class, you havent declared the class. EVERY .java file you create is a CLASS. The compiled files' extension is even .CLASS. The absolute first thing you do when...
  4. Replies
    7
    Views
    3,727

    [SOLVED] Re: I thought that this would be right?

    We cant know what your error is without knowing whats on the line you get an error on is. Your code seems fine, but the error is somewhere else, prolly inside the main function where you run your...
Results 1 to 4 of 4