Results 1 to 2 of 2

Thread: Getting an inaccessible code error

  1. #1
    anna26 is offline Senior Member
    Join Date
    Dec 2008
    Posts
    147
    Rep Power
    4

    Default Getting an inaccessible code error

    I keep getting an inaccessible code error. Why? Community static int[] read Array(Scanner keyboard, int numElements) {throw novel Unsupported Operation Exception("TODO - implement");
    int a[];
    for (int i=0; i< numElements; i++){
    a[i] = keyboard.nextInt();
    }
    Return a;
    }

  2. #2
    adny22 is offline Senior Member
    Join Date
    Dec 2008
    Posts
    148
    Rep Power
    4

    Default

    Since the keyword "throw" means to flings an exemption so at the line
    fling novel unconfirmed Operation Exception("TODO - implement");
    Your read Array technique will stop carrying out and pass control to the next available exemption handler. As your throw call is on the main line of carrying out, it will forever be thrown, and nothing lower that will ever be executed.

Similar Threads

  1. Getting an inaccessible code error why
    By Davismoore in forum other peripherals
    Replies: 1
    Last Post: 06-30-2010, 03:40 PM
  2. Error Code 0x800B0004
    By John Dyson in forum Windows XP
    Replies: 0
    Last Post: 08-07-2009, 01:44 PM
  3. Error code problem
    By Johnny Cuzens in forum Windows 7/2000/NT
    Replies: 0
    Last Post: 07-26-2009, 12:05 PM
  4. Error code 1500
    By Austin in forum Windows XP
    Replies: 1
    Last Post: 04-25-2009, 12:34 PM
  5. Error Correction Code (ECC) RAM
    By vandana43 in forum RAM
    Replies: 0
    Last Post: 03-19-2008, 10:06 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
SEO by SubmitEdge

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48