#include <iostream>
#include <string>
using namespace std;
int main() {
int t;
cin >> t;
while (t--) {
int n, a, q;
cin >> n >> a >> q;
string notifications;
cin >> notifications;
int online = a;
bool allRead = true;
bool impossible = false;
for (char notification : notifications) {
if (notification == '+') {
online++;
if (online > n) {
impossible = true;
break;
}
} else {
online--;
if (online < 0) {
impossible = true;
break;
}
}
if (online == 0) {
allRead = false;
}
}
if (impossible) {
cout << "NO" << endl;
} else if (allRead) {
cout << "YES" << endl;
} else {
cout << "MAYBE" << endl;
}
}
return 0;
}