Become a member
Sign in

var totalPrice = 0, fruitsPrice = 0, i, line;
for(i=0; i<shopingList.length; i++){
line = shopingList[i];
totalPrice += line.units * line.price;
if (line.type …

Make your code easier to read with Functional Programming
6.6K
23
Cristian Salcescu
Fabrizio Fiandanese
Fabrizio Fiandanese
Sep 9, 2018 · 1 min read

Small typo…

    Fabrizio Fiandanese

    Written by

    Fabrizio Fiandanese

    Write the first response

    Discover Medium

    Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch

    Make Medium yours

    Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore

    Become a member

    Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade
    AboutHelpLegal