Created
July 27, 2020 23:26
-
-
Save beatak/b4647fd815ea115e408a2d3e2f5e9ce2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
amounts = []; | |
thetable = document.getElementsByTagName('tbody').item(0) | |
for (item of thetable.getElementsByTagName('tr')) { | |
const mytd = item.getElementsByTagName('td').item(3); | |
const mysize = parseFloat(mytd.textContent.split(' ')[0]); | |
amounts.push(mysize); | |
} | |
amounts.reduce((accum, cur) => { return accum + cur; }, 0) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment