A mass of M kg is suspended by a weightless string. The horizontal force that is required to displace it until the string makes an angle of 45^∘ with the initial vertical direction is