-
-
Save hasangenc0/69ce6498a5044a9d5f5bcfa7c6cf524b to your computer and use it in GitHub Desktop.
Gist bot example
This file contains hidden or 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
table = document.querySelector("table"); | |
sum = 0; | |
for (var i = 0, row; row = table.rows[i]; i++) { | |
for (var j = 0, col; col = row.cells[j]; j++) { | |
if (j ==2 && i > 0) { | |
sum += Number(col.innerHTML.replaceAll(',', '')); | |
} | |
} | |
} | |
console.log({sum}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
comment