I am trying to get a total of price of all the items multiplied by the quantity of the item:
const shoppingCart = {
"tax": .08,
"items": [
{
"title": "orange juice",
"price": 3.99,
"quantity": 1
},
{
"title": "rice",
"price": 1.99,
"quantity": 3
The result I want to get is 9.96. But I'm struggling to come up with a proper way to do so.