testing greedy (y)