To solve this problem we will apply the concepts related to energy conservation. From this conservation we will find the magnitude of the amplitude. Later for the second part, we will need to find the period, from which it will be possible to obtain the speed of the body.
A) Conservation of Energy,


Here,
m = Mass
v = Velocity
k = Spring constant
A = Amplitude
Rearranging to find the Amplitude we have,

Replacing,


(B) For this part we will begin by applying the concept of Period, this in order to find the speed defined in the mass-spring systems.
The Period is defined as

Replacing,


Now the velocity is described as,


We have all the values, then replacing,


Frequency = (speed) / (wavelength)
Speed = 3 x 10⁸ m/s
Wavelength = 3 cm = 0.03 m
Frequency = (3 x 10⁸ m/s) / (0.03 m)
Frequency = (3 x 10⁸ / 0.03) (m / m-s)
Frequency = 1 x 10¹⁰ Hz (10 Gigahertz)
%d is a format specifier that is a placeholder for an int value. It tells the compiler that we want to print an integer value that is present in variable a. In this way there are several format specifiers in c.
Simply draw the vector with the given coordinates.