#include using namespace std; typedef long long ll; templatebool chmax(T &a, const T &b) { if (abool chmin(T &a, const T &b) { if (b>N; vector S={"akai","marui","okii","umai"}; sort(all(S)); int ans=0; while(N--){ vector T(4); for(int i=0;i<4;i++) cin>>T[i]; sort(all(T)); if(S==T) ans++; } cout<