代码练习
#include <iostream>
using namespace std;
string s1, s2;
int main(void) {
cin >> s1 >> s2;
int n1 = 1, n2 = 1;
for (const auto& c : s1) n1 *= c - 'A' + 1;
for (const auto& c : s2) n2 *= c - 'A' + 1;
n1 %= 47, n2 %= 47;
puts(n1 == n2 ? "GO" : "STAY");
}