Repository navigation
Conversation
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your implementation successfully meets all the task requirements. The code correctly retrieves population data from spans, converts strings to numbers, calculates both total and average values, formats them with thousands separators using your custom insertSeparators function, and replaces the 'Calculate it!' placeholder text in the target elements. All checklist items pass, including the correct username in the demo link.
There are two minor improvements you could consider for future robustness: using el.classList.contains(searchClass) instead of exact class matching (currently works fine with your HTML structure), and using more descriptive variable names like formattedTotal and formattedAverage instead of totalSep and averageSep. These are optional refinements that don't affect the current functionality.
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
DEMO LINK