



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




which are initialized by an array.
access modifier applicable only to a variable, a method, or a class. The following are different contexts where final is used. When a variable is declared with the final keyword, its value can’t be modified, essentially, a constant.
class finalnumber { public static void main(String[] args) { // Declaring and initializing. int arr[] = { 1, 2, 3 }; //Restore initializing value in final number. for (final int i : arr) System.out.print(i + " "); } }
//finally block Finally { System.out.println("Finally block."); } } }
Name : Abu Saied Mohammad Tarek ID : 666-46- Batch : 46 th E-mail ID : [email protected] Date of Assignment : 18-10- Date of Submission : 25-10- Contact No. : 01841- Signature of Student : Course Teacher : Nishu Chowdhury (Lecturer)