An array is a variable in JavaScript used to store data. Arrays are used when we have a large list of data and we want to store it to access it one by one.
For more information about arrays, how to create them in JavaScript and how to add, remove elements and join multiple arrays please check the following tutorial:Â https://purpose-code.com/javascript-arrays-how-and-what/
2)- How to loop through an array?
1)- For loop
To loop through an array the 1st common method is to use the for loop method.
The for loop method will run through the elements of the array, but it does not look for the element itself, but for its index/position in the array.
Letâs take an example to see how for loop works exactly.
To continue reading you can check the complete article below:
Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
â Live Streamingâ Interactive Chatâ Private Showsâ HD Quality
Anya is LIVE right now
FREE
Free to watch ⢠No registration required ⢠HD streaming
If you have not downloaded Visual Studio Code or not know what it is, this is a brief guide on it :3
VISUAL STUDIO CODE:Â It is a source-code editor, made by Microsoft for Windows, Linux and MacOS. It supports Javascript, HTML, CSS, Java, Python and several other programming languages as well. Itâs easy to use and very beginner-friendly (at least to me, it is).
For any platform, you can download your Operating Systemâs version from:Â https://code.visualstudio.com/Â
There is a whole Introduction video that you can watch to understand how Visual Studio Code works: https://code.visualstudio.com/docs/getstarted/introvideos
Node JS
If youâre here because youâre coding a discord bot using Javascript or youâre just coding something using Javascript, Node JS can help you. It is basically a Javascript runtime application.
You can download it from:Â https://nodejs.org/en/download/
How it works:
1. Create a new file called âhello.jsâ and fill it up with the code as shown above.
2. Go to your terminal. (For those who might not know, you can click Terminal from the top tab > New Terminal. This will pull up the console for you.
3. Make sure that the directory of your terminal is the place where your hello.js file is at. If not, you can always use ls to list the different folders in that directory and cd to change into that directory as shown below:
My terminal was in the Github folder and I used ls to list all the folders in the Github folder. From there, I can see the cafe-bot folder where my hello.js file is located in. So I used cd cafe-bot to move into that folder.
4. Run node hello.js and you will see âHello Worldâ, which is what your code was supposed to output.
And there you have it! I hope that was a simple and easy-to-understand explanation on Visual Studio Code and Node JS.
Error You Might Face:
Sometimes when you run node for the first time after installing, you might face this error.Â
From what I have noticed, this tends to usually happen to Windows users. Unfortunately, since I am using a MacOS, itâs hard for me to screenshot the process. But no fear, we have Codez Jerry who have the perfect solution here: https://www.youtube.com/watch?v=pg4t48BPmh8
Have fun coding! If you have any troubles, do send me a message or just Ask and I will do my best to help and add on to this guide!
How to build a RESTful API in Node, Express & Mongo in 2019 | Tutorial â https://codequs.com/p/SkUi23MBS/how-to-build-a-restful-api-in-node-express-mongo-in-2019-tutorial #nodejs #javascript
Anya is live and ready to show you everything. Watch her strip, dance, and perform exclusive shows just for you. Interact in real-time and make your fantasies come true.
â Live Streamingâ Interactive Chatâ Private Showsâ HD Quality
Anya is LIVE right now
FREE
Free to watch ⢠No registration required ⢠HD streaming