The time dependence of one-dimensional quantum mechanical probability densities is presented when the potential in which a particle moves is suddenly changed, called a quench. Quantum quenches are mainly addressed, but a comparison with results for the dynamics in the framework of classical statistical mechanics is useful. Analytical results are presented when the initial and final potentials are harmonic oscillators. When the final potential vanishes, the problem reduces to the broadening of wave packets. A simple introduction to the concept of the Wigner function is presented, which allows a better understanding of the dynamics of general wave packets. It is pointed out how special the broadening of Gaussian wave packets is, the only example usually presented in quantum mechanics textbooks.