The commencement of proceedings in the case of contests of the second, third, fourth and fifth classes shall be by petition, which shall be made and filed, as herein required, within twenty days after the day of the primary or election, as the case may be. The petition shall concisely set forth the cause of complaint, showing wherein it is claimed that the primary or election is illegal, and after filing may be amended with leave of court, so as to include additional specifications of complaint.
In each of the aforesaid second, third, fourth and fifth classes, the petitioners shall be registered electors who voted at the primary or election so contested. In cases of the third class, each petition shall be verified by the affidavits of at least ten of the petitioners; in the second, fourth and fifth classes, by the affidavit of at least five of the petitioners. Such affidavits shall be taken and subscribed before some person authorized by law to administer oaths, and shall set forth that