Reduce
The reduce method reduces an array to a single value by applying a function to each element.
Basic reduce
Loading JavaScript Playground...
Understanding reduce
Loading JavaScript Playground...
Common reduce Patterns
Loading JavaScript Playground...
Advanced reduce
Loading JavaScript Playground...
Exercise: Sum Array
Use reduce to sum an array:
Loading JavaScript Exercise...
Exercise: Find Maximum
Use reduce to find the largest number:
Loading JavaScript Exercise...
Up next · Lesson 27 of 37
Object Basics
1 min read
26 of 37 lessons done

Ask Byte about this lesson
A private chat about this lesson. Byte has read the whole lesson, answers in seconds, and shows the section each answer comes from. Ask follow-ups in any language.
Questions & Answers
Public questions about this lesson. The AI Tutor answers right away in your language, the FreeAcademy team checks answers, and every learner can read them.

