Submission #934089

#TimeUsernameProblemLanguageResultExecution timeMemory
934089darya_navardGTA (COI14_gta)C++17
0 / 100
11 ms10896 KiB
#include <bits/stdc++.h> using namespace std; const int N = 110; int n; string s[N]; int main() { ios:: sync_with_stdio(0), cin.tie(0); cin >> n; for (int i = 0; i < n; i++) cin >> s[i]; for (int i = 0; i < n; i++) { for (int j = 0; j < n; j++) { bool flag = false; if (s[i].size() == 2 && s[j].size() == 1) swap(s[i], s[j]), flag ^= 1; if (s[i].size() == s[j].size() && s[i] == s[j]) cout << 1; if (s[i] == "G" && s[j] == "CT") cout << 1; else if (s[i] == "T" && s[j] == "GA") cout << 1; else if (s[i] == "A" && s[j] == "TC") cout << 1; else if (s[i] == "C" && s[j] == "AG") cout << 1; else cout << 0; } cout << endl; } }
#Verdict Execution timeMemoryGrader output
Fetching results...