#include <bits/stdc++.h>
using namespace std;
int dx[] = {1, -1, 0, 0};
int dy[] = {0, 0, -1, 1};
void arquivo() {
  freopen("", "r", stdin);
  freopen("", "w", stdout);
}
const int N = 8;
string s[N];
int main() {
  for (int i = 0; i < 8; ++i) cin >> s[i];
  int ma, mb;
  ma = mb = 0x3F3F3F3F;
  for (int i = 0; i < 8; ++i) {
    for (int j = 0; j < 8; ++j) {
      if (s[i][j] == 'W') {
        int ok = 0;
        for (int k = 0; k < i; ++k) {
          if (s[k][j] == '.') continue;
          ok = 1;
          break;
        }
        if (!ok) ma = min(i, ma);
      } else if (s[i][j] == 'B') {
        int ok = 0;
        for (int k = i + 1; k < 8; ++k) {
          if (s[k][j] == '.') continue;
          ok = 1;
          break;
        }
        if (!ok) mb = min(mb, 8 - i - 1);
      }
    }
  }
  int ok = 0;
  if (ma > mb) ok = 1;
  printf("%c\n", ok + 'A');
  return 0;
}
