This question already has an answer here:
For an incident photon to be absorbed by a material, must it exactly equal a difference in the electron energy levels, or does it just have to be more than one such difference. If more is okay, what happens to the remaining photon energy? Does it continue on as a lower energy photon, if so, the remnant photon might not have enough energy to be absorbed. Would it just continue to travel onward through the material indefinitely? Can one or more electrons be knocked off by a single photon? The concepts of exact energy levels sounds a bit unnatural, like perfect sine wave. Are there uncertainty bands in these electron energy levels?