In the photoelectric effect, the work function represents the amount of work that the incoming photon must do in order to extract one electron from the metal.
The energy of the incoming photon is equal to:

where

is the Planck's constant, and f is the photon frequency.
Part of the energy of the photon is used to extract the electron from the metal (work function

), and the rest is converted into kinetic energy K of the electron:

We can find the threshold frequency

, i.e. the minimum frequency needed to extract the electron, by requiring K=0:

Using

, we find

The problem asks to find the corresponding wavelength (i.e. the maximum wavelength able to extract the electron from the metal), which is

where c is the speed of light.