Search:

Type: Posts; User: itayj

Search: Search took 0.06 seconds.

  1. Replies
    16
    Views
    5,739

    Re: using java.util.InputMismatchException with try

    yes,my question hasnt queit been answered , i would like to know if there is a simpler way of making a loop with java.util.InputMismatchException in try.
    somthing that doesn't involve any complexed...
  2. Replies
    16
    Views
    5,739

    Re: using java.util.InputMismatchException with try

    well, i didnt understand this code since the only import i know is java.util.* :P
  3. Replies
    16
    Views
    5,739

    Re: using java.util.InputMismatchException with try

    this is a lot more complexed then i thought it would be i think i will pass since i cant understand most of this code
  4. Replies
    16
    Views
    5,739

    Re: using java.util.InputMismatchException with try

    you do not understand the problem
    it has nothing to do with the loop.
    try running it yourself
    you will get this output if u will enter any other type of input then int:

    Intput Error !
    Intput...
  5. Replies
    16
    Views
    5,739

    Re: using java.util.InputMismatchException with try

    i want the loop to keep going until the right type of input will be inseted
    if i remove flag=true; there is no need for a loop since it will be over the first time
  6. Replies
    16
    Views
    5,739

    using java.util.InputMismatchException with try

    iv writen this code in order to prevent an unexpected ending of program in case there is an input mismatch

    static int smartInputInt ()
    {
    boolean flag=true;
    int end=-10;
    while (flag)...
Results 1 to 6 of 6