MOSCOW — The weekend anticorruption protests that roiled Moscow and nearly 100 Russian towns clearly rattled the Kremlin, unprepared for their size and seeming spontaneity. But perhaps the biggest surprise, even to protest leaders themselves, was the youthfulness of the crowds.

A previously apathetic generation of people in their teens and 20s, most of them knowing nothing but 17 years of rule by Vladimir V. Putin, was the most striking face of the demonstrations, the biggest in years.

It is far from clear whether their enthusiasm for challenging the authorities, which has suddenly provided adrenaline to Russia’s beaten-down opposition, will be short-lived or points to a new era. Nor is it clear whether the object of the anger — blatant and unabashed corruption — will infect the popularity of Mr. Putin.

But the harshness of the response to the protests on Sunday — hundreds of people were arrested, in many cases simply for showing up — suggested that Mr. Putin’s hierarchy was taking no chances.