Simple Java mistake : <pre><code>package e.power.bhd;
</code></pre>

<p>import java.util.Scanner;</p>

<p>public class EPowerBhd {</p>

<pre><code>public static void main(String[] args) {
    int accountNum = 1;
    double cMeter;
    double pMeter;
    double eUsage;
    double totalDueAmount = 0.0;
    double Tot = 0.0;
    Scanner input = new Scanner(System.in);

        while (accountNum != 0) {

            // user enter account no
            System.out.print("Enter Account number (0 to stop ) : ");
            accountNum = input.nextInt();
            // user enter current meter reading
            System.out.print("Current meter reading : ");
            cMeter = input.nextDouble();
            // user enter previous meter reading
            System.out.print("Previous meter reading : ");
            pMeter = input.nextDouble();
            eUsage = cMeter - pMeter;
            System.out.print("Electricity Usage(in kWh) : " + eUsage);
            System.out.println();

            if (eUsage &gt;= 1 &amp;&amp; eUsage &lt;= 200) {
                totalDueAmount = 0.218 * eUsage;
            } else if (eUsage &gt; 200 &amp;&amp; eUsage &lt;= 300) {
                totalDueAmount = 0.334 * eUsage;
            } else if (eUsage &gt; 300 &amp;&amp; eUsage &lt;= 600) {
                totalDueAmount = 0.516 * eUsage;
            } else if (eUsage &gt; 600 &amp;&amp; eUsage &lt;= 900) {
                totalDueAmount = 0.546 * eUsage;
            } else {
                totalDueAmount = 0.571 * eUsage;
            }
            System.out.println();  // total amount for the account is displayed
            System.out.println("Amount number : " + accountNum + "," + " your charge is " + "RM" + totalDueAmount);
            Tot = totalDueAmount++;
            System.out.println();

        } // loop exit and displa the total amount for all accounts
        System.out.println("Total Amount collected  = " + "RM" + Tot);
        System.out.println("________________________________");
        System.out.println("--- DONE ----");
        System.out.println("________________________________");

    }

}
</code></pre>

<p>I have completed a java program in which  the user enter account number, current meter reading and previous current reading and then calculates electricity usag 
It will calculate electricity usage for accounts until user terminates the loop by entering 0 and  the total for all accounts are calculated  and displayed.</p>

<p>In this program if user enter 0 at first it should show
"No account has been processed." only   and  terminates.</p>

<p>Attached is the program code and detail of the program.</p>

<p><a href="https://www.dropbox.com/s/85mm1w09tl7c1n3/1.png?dl=0" rel="nofollow noreferrer">https://www.dropbox.com/s/85mm1w09tl7c1n3/1.png?dl=0</a>
<a href="https://www.dropbox.com/s/8w0ngjt9em70q7w/2.png?dl=0" rel="nofollow noreferrer">https://www.dropbox.com/s/8w0ngjt9em70q7w/2.png?dl=0</a></p>

<p>Any help is mostly appreciated..</p>
