#include <iostream>
#include <complex>
using namespace std;

#define EPS 1.e-6
typedef complex<double> C;

C v[4];
double r;

double dot(C &a, C &b) {
  return a.real()*b.real() + a.imag()*b.imag();
}

double ncross(C &a, C &b) {
  return a.real()*b.imag() - a.imag()*b.real();
}

int tri_in_check() {
  int c[3];
  C a;
  double r2 = r*r;
  for (int i=0; i<3; i++) {
    a = v[i] - v[3];
    if (norm(a) < r2) {
      c[i] = -1;
    } else if (norm(a) > r2){
      c[i] = 1;
    } else {
      c[i] = 0;
    }
  }
  if (c[0]>=0. && c[1]>=0. && c[2]>=0.) {
    return 1;
  } else if (c[0]<=0. && c[1]<=0. && c[2]<=0.) {
    return -1;
  }
  return 0;
}

bool center_in_check() {
  C a, b;
  bool f[3];
  for (int i=0; i<3; i++) {
    a = v[(i+1)%3] - v[i];
    b = v[3] - v[(i+1)%3];
    f[i] = (ncross(a,b) > 0);
  }
  return (f[0]==f[1] && f[0]==f[2]);
}

int intersect() {
  C a, b;
  double na, nb, dab, d, sd, s, t;
  bool contact = false;
  for (int i=0; i<3; i++) {
    a = v[(i+1)%3] - v[i];
    b = v[3] - v[i];
    na = norm(a);
    nb = norm(b);
    dab = dot(a,b);
    d = dab*dab - na*(nb-r*r);
    if (d < -EPS) {
      continue;
    } else if (fabs(d) < EPS) {
      d = 0.;
    }
    sd = sqrt(d);
    s = (dab+sd)/na;
    t = (dab-sd)/na;
    if ((s>EPS&&s<1.-EPS) || (t>EPS&&t<1.-EPS)) {
      if (fabs(d) < EPS) {
        contact = true;
      } else {
        return 1;
      }
    }
    if (fabs(s)<EPS || fabs(s-1.)<EPS || fabs(t)<EPS || fabs(t-1.)<EPS) {
      contact = true;
    }
  }
  return (contact ? 0 : -1);
}

int main() {
  int t;
  while (1) {
    cin >> v[0].real() >> v[0].imag();
    if (!v[0].real() && !v[0].imag()) break;
    for (int i=1; i<4; i++) {
      cin >> v[i].real() >> v[i].imag();
    }
    cin >> r;
    if (tri_in_check() == -1) {
      cout << "b" << endl;
    } else {
      t = intersect();
      if (t == 1) {
        cout << "c" << endl;
      } else if (center_in_check()) {
        cout << "a" << endl;
      } else if (t == 0) {
        cout << "c" << endl;
      }  else {
        cout << "d" << endl;
      }
    }
  }
  return 0;
}