Exiting do-while loop with string input in java
<p>I was trying to write the following code to allow continuous coin toss and exits when E is entered. Not sure if do-while loop is the correct way to do it continuously or i should use another method. </p>

<pre><code>do {
    guess = sc.next();
    tossGenerator(guess);
    }while(!guess.equals("E")||!guess.equals("e"));
</code></pre>

<p>So, did I phrase the code wrongly because I can't get out of the do loop or a different method should be used. Please help. Thanks. </p>
