#include <bits/stdc++.h>
using namespace std;
int n;
const int N = (int)1e4 + 10;
long long x[N], y[N], z[N];
long long px, py, pz;
long long vp, vs;
long double tx, ty, tz;
bool ok(long double tt) {
  long double t = tt;
  int i = 0;
  tx = 0;
  ty = 0;
  tz = 0;
  while (i < n - 1) {
    long double per = sqrt(((x[i + 1] - x[i]) * (x[i + 1] - x[i])) +
                           ((y[i + 1] - y[i]) * (y[i + 1] - y[i])) +
                           ((z[i + 1] - z[i]) * (z[i + 1] - z[i]))) /
                      vs;
    if (t < per) {
      tx = x[i] + ((x[i + 1] - x[i]) * t) / per;
      ty = y[i] + ((y[i + 1] - y[i]) * t) / per;
      tz = z[i] + ((z[i + 1] - z[i]) * t) / per;
      break;
    } else
      t -= per;
    i++;
  }
  if (i == n - 1) {
    tx = x[n - 1];
    ty = y[n - 1];
    tz = z[n - 1];
  }
  return (((tx - px) * (tx - px)) + ((ty - py) * (ty - py)) +
              ((tz - pz) * (tz - pz)) <=
          vp * vp * tt * tt + 1e-8);
}
int main() {
  scanf("%d", &n);
  n++;
  for (int i = 0; i < (int)n; ++i)
    scanf("%I64d%I64d%I64d", &x[i], &y[i], &z[i]);
  scanf("%I64d%I64d", &vp, &vs);
  scanf("%I64d%I64d%I64d", &px, &py, &pz);
  long double l = 0;
  long double r = 1e-7;
  for (int i = 0; i < (int)n - 1; ++i)
    r += sqrt(((x[i + 1] - x[i]) * (x[i + 1] - x[i])) +
              ((y[i + 1] - y[i]) * (y[i + 1] - y[i])) +
              ((z[i + 1] - z[i]) * (z[i + 1] - z[i]))) /
         vs;
  for (int i = 0; i < (int)100; ++i) {
    long double m = (l + r) / 2;
    if (ok(m))
      r = m;
    else
      l = m;
  }
  if (ok(r))
    printf("YES\n%.20lf\n%.20lf %.20lf %.20lf\n", (double)r, (double)tx,
           (double)ty, (double)tz);
  else
    puts("NO");
  return 0;
}
