This Javascript tutorial covers Javascript arrays and looping arrays in Javascript. Arrays store lists of items of any type. You can iterate a Javascript array with loops, making it easy to run actions on all of the items in the array.
This is a Free Javascript Course designed for beginners. These Javascript lessons cover the basics of Javascript and programming basics from the very beginning.
Original source
41 responses to “Javascript Tutorial For Beginners – #4 Javascript Arrays & Loops”
Thanks you so much for these videos. I love learning these things without paying a dime.
so sincerely appreciate for u sharing so great video. thx ๐
html and css where super easy, javascript is super HARD!
7:25 is the good spot XD
Also, awesome video! You helped me a lot in coding my own bot (even though i'm unsure if it will work as I plan it, but so much for that). You earned yourself a sub. =)
great explanation ?thx
nice tutorial…thanks…can u suggest me good books for javascript for beginners?
im not good at looping please help ๐
Where is the project source code?
Or how to create one project as the same tree in the vedio
Is this good usage of while loop? (it's for last FOR loop example)
var myList = ['bananas', 'oranges', 'apples'];
var i=0;
while (i<myList.length) {
alert("You have "+ myList[i] +" in your basket")
i=i+1
You just cleared it up for me cheers, been struggling with looping through arrays for a 'while' now lol no pun intended
outputing text will be hard to get used to because i am used to the c++ syntax for out putting text on the screen, which has no + sign between the 2 strings… it is seperated by a cheveron as i like to call the operator "<<"
does the foreach need that fucntion(value, index) or can it be something else like a function we make?
while (1<2)
Fun Learning. Thanks Will ๐
you made it so simple, thanks a lot
Great videos
Please see the 'homework' below: –
//Functions are a piece of code that does one or more actions
//Do not repeat yourself DRY
function add(first, second){
return first+second;
}
function subtract(first, second){
return first-second;
}
function multiply(first,second){
return first*second;
}
function divide(first, second){
return first/second;
}
alert(add (9, 3));
alert(subtract (9, 3));
alert(multiply (9, 3));
alert(divide (9, 3));
why do we use new array() in arrays?
I added the script tag into the HTML file but still got the same error
"VM73:1 Uncaught ReferenceError: myList is not defined"
I am using atom on windows 7.
any help would be appreciated
Very clear teaching. Good teacher.
this literally saved me thank you
Please help! I don't understand library mode :S how can I connect my JS console to Sublime? Thanks!
very well explained
Your tutorials are dog shit. Suck a dick.
i'm following along and i linked my js to my html but i don't see you show your css anywhere, i'm OCD that way and i need it lol
Which application are you using to develop/run the code?
the developer console shows only the last value of the ones i put in the array
any explanation?
wow u just made looping so much easier. .
Man you are so good… RESPECT…
very well explained! ๐
Thanks +LearnCode.academy I've been doing one of these lessons a day and I'm progressing incredibly! Your teaching videos are really helping me learn the basics of javascript. I even have some of my own scripts already!
I understand left side is sublime and right side is chrome, but how do you connect them ? I guess that localhost:9000 does the magic. Thanks for the great instructions.
What program are you using to write the code in?
good tutorial, I recommend that course to learn well javascript beginner – medium?
Probably a stupid question but this my first video here. How are you inputting the code into the browser? Is it an IDE or are you typing it into the console? How is it connecting to the code and the browser
What is that window. please tell me how to use it
awesome explanation thank you so muchhh!!!
How do you connect the main.js file to the console? I had trouble with that.
jason bateman teaching code
bro ' i really like the way you teach , how many years of experience you have in javascript ? i want to be advanced like you , i just started to learn it weeks ago i created rock paper scissor game on my own … ! tell me .
i have never seen loops been explained in that easy manner… great..
Great videos, thank you. Question. What're the implications of JS treating functions as variables? Is this customary in programming languages?