(a) Any railroad company, express company or other carrier or any person or corporation violating any of the provisions of this article or failing to comply with any requirements thereof shall be guilty of a misdemeanor, punishable by a fine of not less than $50.00 nor more than $500.00, to which, at the discretion of the court, may be added imprisonment in the county jail or confinement at hard labor for the county for not more than six months for the first conviction. On the second and every subsequent conviction of a violation of any provisions of this article, the offense shall, in addition to a fine within the limitations above named, be punishable by imprisonment in the county jail or at hard labor for the county for not less than three nor more than six months, to be imposed by the court.