Section 7A. Cities and towns may appropriate money for the purpose of conducting and maintaining a specific program of safety activities designed to prevent automobile accidents; and such appropriations shall be expended under the direction of the mayor in a city or the selectmen in a town.