add modulo to split rows