how to append a list in js code example
Example 1: javascript append list
var fruits = ["Banana", "Orange", "Apple", "Mango"];
fruits.push("Kiwi");
Example 2: javascript adding an array to an array
let chocholates = ['Mars', 'BarOne', 'Tex'];
let chips = ['Doritos', 'Lays', 'Simba'];
let sweets = ['JellyTots'];
let snacks = [];
snacks.concat(chocholates);
snacks.concat(chocolates, chips, sweets);
Example 3: javascript append array to end of array
const new_array = old_array.concat([value1[, value2[, ...[, valueN]]]])