Beginner Java Tutorial #7: Arrays in Java

///Beginner Java Tutorial #7: Arrays in Java

Beginner Java Tutorial #7: Arrays in Java

FavoriteLoadingAdd to favorites

TAKE THE QUIZ FOR THIS VIDEO!:

Java468x60

In this video we show how to declare and initialize arrays.

Follow me:

source

By |2020-02-25T01:56:45+00:00February 25th, 2020|Java Video Tutorials|15 Comments

15 Comments

  1. Mofreh Sarhan February 25, 2020 at 1:56 am - Reply

    Thank you so much for sharing and uploading

    I really appreciate posting these videos, they really helped me to further solid my understanding of Java language.

  2. Edd G. February 25, 2020 at 1:56 am - Reply

    I'm a beginner, but how is this easier than assigning variables to the names? Like you said, if you have 1,000 names to write down, that would be too many. This still seems to be the case…thanks and your videos are so much easier to understand than my text book!

  3. Isam Al-Abbasi February 25, 2020 at 1:56 am - Reply

    Hello Shane, I recently came across your website and I really appreciate posting these videos, they really helped me to further solid my understanding of Java language.

  4. Nihal Khurana February 25, 2020 at 1:56 am - Reply

    But what if you wanted to print out all of the data in the array?

  5. Freetechtorials February 25, 2020 at 1:56 am - Reply

    Hey all,
    It has been pointed out that the code at the end of this tutorial is incorrect.  Thank you to those that caught this error and I apologize for my oversight.  In Java, arrays must be given an initial size if you do not immediately add values to the array.  Therefore, the array declaration should be as follows;  String[3] testTakers = new String[];  This tells java that we expect to have 3 items in our array but we have not yet said what the value of those items are.  Please let me know if there are any more questions. Thanks 

  6. Boma Boma February 25, 2020 at 1:56 am - Reply

    Thank you

  7. KMCGamer February 25, 2020 at 1:56 am - Reply

    I was under the assumption that arrays once declared were not allowed to expand or shrink in size. I dont understand how your last example would work when essentially you're not giving the array a size to start with, unless its zero.

  8. Barnabás Juhász February 25, 2020 at 1:56 am - Reply

    Hi, when I try to run this at the end, I get the following error message:
    "Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 0
        at Tutorial7_Arrays.main(Tutorial7_Arrays.java:8)"

  9. Sami Haddad February 25, 2020 at 1:56 am - Reply

    Thanks man, I've tried the new bostons and stuff, but theirs was way too hard, and I didn't known anything about programming, now, I'm trying yours, and until now, it's awesome! Thanks a lot, if there's a load on you in the editing part, I can take over, I can edit videos if you feel lazy.

  10. Freetechtorials February 25, 2020 at 1:56 am - Reply

    Thanks for all the comments. I know I take forever to get videos out, I've been pretty busy. I have not given up though, so stay tuned. All of the java tutorials will be added to the Java playlist to make them easier to find.

  11. Jitendrasing Solanki February 25, 2020 at 1:56 am - Reply

    Where is tutorials?????

  12. Sir Plus February 25, 2020 at 1:56 am - Reply

    Thanks so much, :).

  13. Nathanael Pillay February 25, 2020 at 1:56 am - Reply

    finally u take soooooo long to make more man

  14. Freetechtorials February 25, 2020 at 1:56 am - Reply

    Thanks, I plan on doing many more in the very near future.

  15. NCEats February 25, 2020 at 1:56 am - Reply

    Nice, keep'em coming!

Leave A Comment

*