A more recursive strategy with less use of reduce