#include<fstream>
#include<set>
#include<string>
std::ifstream cin("poker.in");
std::ofstream cout("poker.out");
int main(){
    std::set<std::string> s;
	int n;
    cin>>n;
	for(int i=1;i<=n;i++){
		std::string t;
		cin>>t;
		s.insert(t);
	}
	cout<<52-s.size()<<'\n';
	return 0;
}