John is planning a party. There are 28 pieces of carrot cake and 7 pieces of marble cake. He wants to create plates with the same number of each type of cake. What is the greatest number of plates he can create?