removed reduce from loop