What is happening on that time when John Updike wrote the story? Is it the story are related to the things that happend at the moment?
This short story was published in 1961. The 50s and early 60s in suburban America was a time period most known for its conservativism. Conservative spending, conservative dress, conservative family values, etc. This is a time when houses remained unlocked, neighbors were neighborly, and generally speaking, society followed an unwritten code for social behavior. (Remember, this era directly precedes the rebellious hippy movement of the late 60s and early 70s).
Sammy represents an attitude that was coming, quickly, at this time, for many young Americans. The girls in the A&P are embarrassed when reprimanded for their attire (they hardly seem to notice the stares and scowls from older onlookers) and Sammy is embarrassed as well. In the moment that he quits, he is making a statement - taking a stand - socially, that he disagrees with the unwritten rules that society imposes.
Because the story is told from the perspective of America's youth, it obvious that the conflict is between the older generation and the younger one. Clearly, Updike was writing about the oncoming shift in values as teens and twenty somethings were about to rise up and begin to create a voice for themselves - through music, in politics, in protest, and in simply ceasing to follow the unwritten code of decency.