标签:binary orm 技术 setting mat c++ turn problem close
A.Competitive Problem Setting
#include <bits/stdc++.h> typedef long long ll; const int maxn = 1e5+7; using namespace std; string s,s1; set<string>ss; int main(){ int T; cin>>T; while(T--){ int n; cin>>n; ss.clear(); int flag = 0; for(int i=0;i<n;i++){ cin>>s; s1 = s.substr(0,3); if(flag==0&&ss.count(s1)){ flag = 1; } else ss.insert(s1); } if(flag) cout<<"No"<<endl; else cout<<"Yes"<<endl; } return 0; }
标签:binary orm 技术 setting mat c++ turn problem close
原文地址:https://www.cnblogs.com/Tianwell/p/11686959.html