generator+join will be both shorter and faster for this.