NEW ALGORITHM. uses addition