Use Of Reduce Function In Javascript Example