Question: https://jsfiddle.net/nLj2r3oo/2/ 1. create a varible named donationTotal set value to zero 2. apply the forEach() method to the donors array using the callback function calcSum()
https://jsfiddle.net/nLj2r3oo/2/
1. create a varible named donationTotal set value to zero
2. apply the forEach() method to the donors array using the callback function calcSum()
3. creat a var summaryTable storint the text of "
| Donors | donors |
|---|---|
| Total Donations | $total |
4. set the innerHTML property of the div element with the ID donationSummary to the value of the summaryTable Var
5. to show donors who donated $1000 or more use the filter() method with the call back function findMajorDonors() creat an array named majorDonors
6. in decending order apply the sort() method to the majorDonors var using the call back function donorSortDescending()
7. creat var named donorTablethat will store the HTML code for the table of major donors set inital value of the var tp the text "
| Donation | Donor ID | Date | Name | Address | Phone |
|---|
10. set the innerHTML property of the div element with the ID donorTable to the value of the donorTable Var
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
