naive implementation to get to green