"According to the Rabbis, the Books of Numbers and Deuteronomy are complementary to each other (comp. Tithe, Biblical Data); consequently there can be no contradiction between them. Thus there were three kinds of tithes: (1) that given to the Levites as stated in Num. xviii. 21 et seq., and termed "the first tithe" ("ma'aser rishon"); (2) the tithe which was to be taken to Jerusalem and there consumed by the landowner and his family, and which was termed "the second tithe" ("ma'aser sheni"), it being taken from what remained after the first tithe had been appropriated; and (3) that given to the poor ("ma'aser 'ani"). Therefore two tithes were to be taken every year except in the seventh year: Nos. 1 and 2 in the first, second, fourth, and fifth years; Nos. 1 and 3 in the third and sixth years."

Source: The Jewish Encyclopedia.