Question: Program language needed is Javascript 1. Create an array of objects named iPhones (apple products). Each of the objects in the array will represent a

Program language needed is Javascript  Program language needed is Javascript 1. Create an array of objects

1. Create an array of objects named iPhones (apple products). Each of the objects in the array will represent a product. * Each object should have properties for: Product Model Inventory Unit price Color ( an array of colors. Eg: ["Purple, "white, Black, Gold"] The array should contain at least 5 iPhone products (chose your own products) You can use an Apple Store web site if you need help finding the info for your products 2. Add a property to each object called: Extra feature to a value: AirDrop to each of the products. Use .forEach() to add the property to each product. 3. Use the sort() method to sort the array of iPhones by rating the most selling products to less selling (most selling means low inventory) 4. Use the .map() method to create an array of iPhones model from initial dataset named iPhoneModel. 5. Use the reduce() method to find the most selling and less selling product in the data set. Store those objects in a variable named most SellingiPhone and less SellingiPhone 6. Use the filter() method to create an array of products that have color property to "Gold". Store the array in a variable named goldiPhones 7. Display the following in the console with text to describe each value: The name of each product (hint: use .join() to make it look nicer * The most selling iPhones and inventory (in parentheses.) The less selling iPhones and inventory * The products that have a color "Gold" Sample Output: iPhone Product Model: iPhone, iPhone3, iPhone 11, iPhone8, ... Most selling product: iPhone6 (2) Less selling products: iPhone11 (10) Gold iPhone products: iPhone 11, iPhone6...... Note: Create your own products, not the same as your classmate

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!