replace "foldLeft(0.0)(a…)" with "(0.0 /: a)(…)"