Skip to content

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

If you ever find yourself writing code like this...

let mentor1 = "Daniel";
let mentor2 = "Irina";
let mentor3 = "Rares";

...then it's probably time to use an array!

Arrays are data structures that hold a list of values.

let mentors = ["Daniel", "Irina", "Rares"];

Arrays can hold any type of value (although almost always you only have one data type per array).

let testScores = [16, 49, 85];
let grades = ["F", "D", "A"];
let greetings = ["Hello, how are you?", "Hi! Nice to meet you!"];