What is Static Array in Java – Core Java – Part – 4


Video is ready, Click Here to View ×

JavaBasics Part – 4 : Static Array in Java

java static 2d array
java static array of objects
constant string array java
java static arraylist
java constant list of strings
how to create a static array java
java statically define array


Subscribe to this channel, and press bell icon to get some interesting videos on Selenium and Automation:


Follow me on my Facebook…

27 thoughts on “What is Static Array in Java – Core Java – Part – 4

  1. Hi Naveen,
    You are a very good teacher and I can understand each and every concept of java through your tutorials with practice. But for particular this Object array concept, I am getting "Type Mismatch" error under the values of ob[1] to ob[5]. It can accept string values without any error but it cannot accept an int, double, char values. Could you please help me out with that?

  2. HI Naveen,

    First of all thank you for the effort. I am a manual tester and trying to switch to automation. My first step to learn java basics and I and sincerely following your videos. In the last 4 days I have completed four java videos sequentially and it is helping me a lot. Please guide me I have to complete within 6 months transformation to Selenium. Should I parallely follow your Selenium videos or first I should complete till java part -15 videos? Again thank you.

  3. Hello Naveen…Thank so much for the wonderful videos starting from core java thru webservices. All these videos helped me learn much about testing. Much appreciate this. Can you try uploading some videos on Mobile testing?

  4. Hello Sir,

    Today I have watch your video and create object and pass int, char, string value but it show can not convert int to object error and same for the double and char. What should I do.


  5. Thank you very much for this videos First time i understand the array concept nicely from strach. These are very helpful. and really you are right compare to all books cannot make my concept clear but watching your video i clear my array concept. .hatsoff to you and your patience,dedication and consistent making of videos for us…….thanks a lot Naveen….Thankyou

  6. Hi Naveen,

    The way u r explaining is awesome, I thought to do online course for java with selenium but now I felt like no use of taking course after watching your videos. Thanks a lot…
    I tried to display int array values in decreasing order but its moving to 3 to -1 instead of going till 3 to 0 bcos of this getting array index out of boundary exception, could you please ping me for loop condition.

  7. Hi Naveen Automation Labs,

    your challenge is 100% done that you said compared to all books to your videos we cannot understand the topics but you did it……teaching is also a challenge I really understood the concepts very well after my MCA now dt too from ur videos its awesome very well explained I am your full time follower…..thank you very very much for your patience to make this videos ….hatsoff to your patience ,dedication and consistent making of videos……thanx a lot Naveen….

  8. Hello Naveen, I find your video very neat and simple. Thanks for that Also could you pls make video on Exceptional handling, annotations? Thanks

  9. Hi Naveen,

    Thank you for the awesome videos. These are very helpful.

    I have a question:

    am able to print individual values onto the console for an Object array. Below is the code and am getting output for this.

    Object ob[]=new Object[6];
    ob[4]= 'M';


    However, when I try to print all the values of Object array using for loop, getting below error.

    Exception in thread "main" java.lang.Error: Unresolved compilation problems:
    The operator < is undefined for the argument type(s) Object, int
    Type mismatch: cannot convert from Object to int
    Type mismatch: cannot convert from Object to int

    at JavaBasics.ArrayConcept.main(ArrayConcept.java:98).

    I am writing my code in the Main method. Can you please let me know, what is the code to print all the values of above Object array.

  10. Hi Naveen,

    Thanks for the knowledge u shared on Java.

    However when I am writing the same lines u showed in the Array in Java video I am getting an error:

    Exception in thread "main" java.lang.Error: Unresolved compilation problems:
    Type mismatch: cannot convert from double to Object
    Type mismatch: cannot convert from char to Object

    Here what I have written:

    Object ob[] = new Object[3];
    ob[0] = "TOM";
    ob[1] = 12.33;
    ob[2] = 'm';

    Can you please let me know why I am getting this error. It ran successfully in the video but not in my eclipse.

    Could be due to Java version or something. Not sure as I am very new to Java.

    Thanks for the effort in advance.

Leave a Reply

Your email address will not be published. Required fields are marked *