#include #include #include #include using namespace std; using ll = long long; using ull = unsigned long long; #define COUT(num,len) cout << fixed << setprecision(len) << num; #define iN int N; cin >> N; #define lN ll N; cin >> N; #define coutY cout << "Yes" << endl; #define coutN cout << "No" << endl; #define arrIn(arr, start, N) for (int i = (start); i < (N); ++i) cin >> arr[i]; #define arrOut(arr, start, N) for (int i = (start); i < (N); ++i) { cout << arr[i] <<" "; } cout << endl; #define arrCopy(arr1,arr2, start, N) for (int i = (start); i < (N); ++i) arr2[i]= arr1[i]; void yn(bool tf) { cout << (tf ? "Yes\n" : "No\n"); } void YN(bool tf) { cout << (tf ? "YES\n" : "NO\n"); } string ABC="ABCDEFGHIJKLMNOPQRSTUVWXYZ"; string abc="abcdefghijklmnopqrstuvwxyz"; //cout << fixed << setprecision(20) << int gcd(int a, int b){ //最大公約数 if(a%b == 0){ return b; }else{ return gcd(b, a%b); } } int lcm(int a, int b){ //最小公倍数 return a*b / gcd(a, b); } int nibun(const std::vector& arr, int key, int begin, int end) { while (begin <= end) { int mid = (begin + end) / 2; if (arr[mid] == key) { return mid; } else if (arr[mid] < key) { begin = mid + 1; } else { end = mid - 1; } } return -1; } int fabs(int a,int b){ if(a-b>0){ return a-b; }else{ return b-a; } } int main() { std::cin.tie(nullptr); std::ios_base::sync_with_stdio(false); ll N,M; cin >> N >> M; vector S(N); for(ll i=0;i> S[i]; } string ans=""; ll G,C,P,GG,CC,PP; vector win(N,0); for(ll i=0;i