My code samples and scripts that I use to hopefully save time in the future. Some may be wrong, as they might represent "what I knew at the time"!
// Basic:
var myArray = [5, 10, 15, 20, 25];
// Nested
var nested = {
"hello":{
"english":"hello",
"french":"bonjour",
"portuguese":"ola"
},
"good day":{...},
"how are you":{...}
}
// Maps
var nums = [4, 9, 16, 25];
var x = nums.map(Math.sqrt)
document.getElementById("demo").innerHTML = x;
2,3,4,5
myArray = [5, 10, 15, 20, 25];
// Note: In JavaScript, dict and "object" are interchangeable
// Most people typically refer to these as objects in JS
var myDict = {"Name": "Scott", "State": "TX"};
# Just plain dictionaries in Python
myDict = {"Name": "Scott", "State": "TX"};