Could use reduce here.