The try block looks for error. Put the thing that might cause the error in there.
The catch blocks will attempt to point out the error and display the error message.
Catching and Handling...
Type: Posts; User: javapenguin
The try block looks for error. Put the thing that might cause the error in there.
The catch blocks will attempt to point out the error and display the error message.
Catching and Handling...
int x = 0;
int y = 0;
if (choice = divide)
{
// input int 1 like normal
boolean secondValueIsZero = true;
while (secondValueIsZero==true)
{
while (! entercode = ("1")&&
entercodeString!= ("2") &&
entercodeString != ("3") &&
entercodeString != ("4") &&
entercodeString != ("5"));
Also, I think with Strings and other Objects,...
Please use:
[highlight=java] code [/highlgiht]
It makes code easier to read.
import javax.swing.JOptionPane;
public class MathDrillLoop {//start program
public static void main (String[]...