How was the problem solved in Green Eggs and Ham

In “Green Eggs and Ham,” the problem unfolds as Sam-I-Am persistently offers a peculiar dish to an unwilling friend. Through relentless persuasion and a touch of curiosity, the friend ultimately discovers that he enjoys the green eggs and ham, transforming resistance into acceptance.