Submission #1081688

#TimeUsernameProblemLanguageResultExecution timeMemory
1081688raphael_heuchlMutating DNA (IOI21_dna)C++17
22 / 100
1567 ms3932 KiB
#include "dna.h" #include <iostream> std::string A, B; void init(std::string a, std::string b) { A = a; B = b; } int get_distance(int x, int y) { int AswapCount = 0, TswapCount = 0; for (int i = x; i <= y; ++i) if (A[i] == 'A' && B[i] == 'T') ++AswapCount; else if (A[i] == 'T' && B[i] == 'A') ++TswapCount; if (AswapCount != TswapCount) return -1; return AswapCount; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...