We should first note that we're dealing with a particle travelling in two dimensions. We're given orthogonal (well lets just call them perpendicular for the time being) components of the particles motion. That is the speed that it travels at in the

direciton is

and in the

direction,

. Since the particle is not solely travelling in the

or

directions (but rather travelling along a combination of the two), the actual speed of the particle (which we will call

will be dependent on the components of speed.
Combining these two components to find the magnitude of

gives
^{2}+\left(\frac{dy}{dt}\right)^{2}})
.
Now sometimes you'll only be given a particle moving in one dimensions (such as in methods), where your speed would just be that of the speed of the particle moving in that direction,

. You may also have a particle in three dimensions when you hit vector calculus, where the magnitude of the speed of the particle is the square root of the sum of the square of the rate of change of distance of each component with respect to time.
So if you only have

and your particle is limited to a single dimension, then your speed is just

, if you have the particle in two dimensions then you need to do what was done in the question above.