parent
7e912ab639
commit
af0f5bae63
@ -1,9 +1,36 @@
|
|||||||
let firstName = 'Asabeneh'
|
let firstName = 'Derrek'
|
||||||
firstName = 'Eyob'
|
firstName = 'Deek'
|
||||||
|
console.log(firstName)
|
||||||
const PI = 3.14 // Not allowed to reassign PI to a new value
|
const PI = 3.14 // Not allowed to reassign PI to a new value
|
||||||
// PI = 3.
|
// PI = 3.
|
||||||
|
|
||||||
|
|
||||||
const arr = []
|
const arr = []
|
||||||
console.log(arr)
|
console.log(arr)
|
||||||
|
|
||||||
|
const numbers = [0, 3.14, 9.81, 37, 98.6, 100] // array of numbers
|
||||||
|
const fruits = ['banana', 'orange', 'mango', 'lemon'] // array of strings, fruits
|
||||||
|
const vegetables = ['Tomato', 'Potato', 'Cabbage', 'Onion', 'Carrot'] // array of strings, vegetables
|
||||||
|
const animalProducts = ['milk', 'meat', 'butter', 'yogurt'] // array of strings, products
|
||||||
|
const webTechs = ['HTML', 'CSS', 'JS', 'React', 'Redux', 'Node', 'MongDB'] // array of web technologies
|
||||||
|
const countries = ['Finland', 'Denmark', 'Sweden', 'Norway', 'Iceland'] // array of strings, countries
|
||||||
|
|
||||||
|
// Print the array and its length
|
||||||
|
|
||||||
|
console.log('Numbers:', numbers)
|
||||||
|
console.log('Number of numbers:', numbers.length)
|
||||||
|
|
||||||
|
console.log('Fruits:', fruits)
|
||||||
|
console.log('Number of fruits:', fruits.length)
|
||||||
|
|
||||||
|
console.log('Vegetables:', vegetables)
|
||||||
|
console.log('Number of vegetables:', vegetables.length)
|
||||||
|
|
||||||
|
console.log('Animal products:', animalProducts)
|
||||||
|
console.log('Number of animal products:', animalProducts.length)
|
||||||
|
|
||||||
|
console.log('Web technologies:', webTechs)
|
||||||
|
console.log('Number of web technologies:', webTechs.length)
|
||||||
|
|
||||||
|
console.log('Countries:', countries)
|
||||||
|
console.log('Number of countries:', countries.length)
|
Loading…
Reference in new issue