
what is assertion in java. what is the use of it?

you have to give the size of an array at the time you initialize the array like int a[]=new int[20]; 20 is the size of array a which is integer type of.
and the the finalize is a predefined method in java which is used by the garbagecollection before collect the unused object. this method used to just make sure that the object is no longer used. i hope its clear to u Mr. lokendra yadav
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.