CAN WE ACCESS THE NON-FINAL LOCAL VARIABLE, INSIDE THE LOCAL INNER CLASS?

Mayank Tripathi

Total Post:807

Points:4035
Posted by  Mayank Tripathi
Java  Nested  Class 
 644  View(s)
Ratings:
Rate this:
  1. Mayank Tripathi

    Post:807

    Points:4035
    Can we access the non-final local variable, inside the local inner class?

    No, local variable must be constant if you want to access it in local inner class.

      Modified On Mar-28-2018 12:50:29 AM

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!