I have a 3 queries in Javascript [on hold]

Find how many failed in each subject. Find the pass percentage in each subject. Find a number of centum in each subject. const studentsList = [ { “id”: “1”, “firstName”: “rajesh”, “lastName”: “kumar”, “sub1”: “35”, “sub2”: “55”, “sub3”: “45” }, { “id”: “2”, “firstName”: “ranjith”, “lastName”: “rajesh”, “sub1”: “56”, “sub2”: “65”, “sub3”: “44” }, {…

Understanding javascript promises and async/await to run synchronous code [duplicate]

This question already has an answer here: Why is the method executed immediately when I use setTimeout? [duplicate] 4 answers I already posted a question on this subject here on StackOverflow. Following the recommendations, I have tried to simplify my question. I don’t understand how to make synchronous code with Promises and their new polished…

Parsing and looping through a javascript array of objects in PHP Laravel

I’m wanting to parse this array of objects into something PHP can read so that I can save it into the database. Here’s the array of objects, this is from a console log, and is what is being sent to my axios post: “user_id”: 4, Array [ Object { “cartID”: “33S”, “id”: 33, “image”: “http://myurl/uploads/5db88f40c857dtest.jpg”,…