Problem: Read a set of coordinates of three different points P1 (x1, y1), P2 (x2, y2), Q (xq, yq) on the plane, and line symmetry with point Q with the straight line passing through point P1 point P2 as the axis of symmetry. Create a program that outputs the point R (x, y) at the position of. Note that the point Q is not on its axis of symmetry.

<image>



input

The input consists of multiple datasets. Each dataset is given in the following format:


x1, y1, x2, y2, xq, yq


x1, y1, x2, y2, xq, yq (real numbers between -100 and 100) are given on one line separated by commas.

The number of datasets does not exceed 50.

output

Print x, y on a single line, separated by blanks, for each dataset. The output may contain an error of 0.0001 or less in real numbers.

Example

Input

1.0,0.0,-1.0,0.0,1.0,1.0
1.0,0.0,0.0,-1.0,3.0,0.0
0.0,1.0,0.0,-1.0,1.0,1.0


Output

1.000000 -1.000000
1.000000 2.000000
-1.000000 1.000000

Solution (in CPP):

Solution:
#include <bits/stdc++.h>

using namespace std;
using ll = long long;
using pii = pair<int, int>;

const double EPS = 1e-10;
int sgn(double d) { return d > EPS ? 1 : d < -EPS ? -1 : 0; }

struct Point {
  double x, y;
  Point() {}
  Point (const double& x, const double& y) : x(x), y(y) {}
  Point& operator += (const Point& other) { x += other.x; y += other.y; return *this; }
  Point& operator -= (const Point& other) { x -= other.x; y -= other.y; return *this; }
  Point& operator *= (const double& factor) { x *= factor; y *= factor; return *this; }
  Point& operator /= (const double& factor) { x /= factor; y /= factor; return *this; }
};
using Vector = Point;
using Polygon = vector<Point>;

Point operator + (const Point&lhs, const Point& rhs) { return Point(lhs.x + rhs.x, lhs.y + rhs.y); }
Point operator - (const Point& lhs, const Point& rhs) { return Point(lhs.x - rhs.x, lhs.y - rhs.y); }
Point operator * (const Point& lhs, const double& factor) { return Point(lhs.x * factor, lhs.y * factor); }
Point operator * (const double& factor, const Point& rhs) { return Point(factor * rhs.x, factor * rhs.y); }
Point operator / (const Point& lhs, const double& factor) { return Point(lhs.x / factor, lhs.y / factor); }
double operator * (const Point& lhs, const Point& rhs) { return lhs.x * rhs.x + lhs.y * rhs.y; }
double operator ^ (const Point& lhs, const Point& rhs) { return lhs.x * rhs.y - lhs.y * rhs.x; }
bool operator == (const Point& lhs, const Point& rhs) { return sgn(lhs.x - rhs.x) == 0 && sgn(lhs.y - rhs.y) == 0; }
bool operator != (const Point& lhs, const Point& rhs) { return !(lhs == rhs); }
bool operator < (const Point& lhs, const Point& rhs) { return sgn(lhs.x - rhs.x) ? lhs.x < rhs.x : lhs.y < rhs.y; }
bool operator > (const Point& lhs, const Point& rhs) { return rhs < lhs; }
bool operator <= (const Point& lhs, const Point& rhs) { return !(lhs > rhs); }
bool operator >= (const Point& lhs, const Point& rhs) { return !(lhs < rhs); }
istream& operator >> (istream& is, Point& point) { return is >> point.x >> point.y; }
ostream& operator << (ostream& os, Point& point) { return os << "(" << point.x << "," << point.y << ")"; }
double norm(const Point& point) { return point.x * point.x + point.y * point.y; }
double abs(const Point& point) { return sqrt(norm(point)); }
double arg(const Point& point) { return atan2(point.y, point.x); }
Point polar(const double& a, const double& r) { return Point(cos(r) * a, sin(r) * a); }
bool sort_x(const Point& lhs, const Point& rhs) { return sgn(lhs.x - rhs.x) ? lhs.x < rhs.x : lhs.y < rhs.y; }
bool sort_y(const Point& lhs, const Point& rhs) { return sgn(lhs.y - rhs.y) ? lhs.y < rhs.y : lhs.x < rhs.x; }

struct Segment {
  Point p1, p2;
  Segment() {}
  Segment(const Point& p1, const Point& p2) : p1(p1), p2(p2) {}
};
using Line = Segment;

istream& operator >> (istream& is, Segment& segment) { return is >> segment.p1 >> segment.p2; }
ostream& operator << (ostream& os, Segment& segment) { return os << "(" << segment.p1 << "," << segment.p2 << ")"; }

Point project(const Segment& s, const Point& p) {
  Vector base = s.p2 - s.p1;
  double r = (p - s.p1) * base / norm(base);
  return s.p1 + base * r;
}
Point reflect(const Segment& s, const Point& p) {
  return p + (project(s, p) - p) * 2.0;
}

int main() {
  cin.tie(0);
  ios_base::sync_with_stdio(false);
  cout << fixed << setprecision(10);
  
  Line l;
  Point p;
  char c;
  while (cin >> l.p1.x >> c >> l.p1.y >> c >> l.p2.x >> c >> l.p2.y >> c >> p.x >> c >> p.y) {
    Point ans = reflect(l, p);
    cout << ans.x << " " << ans.y << endl;
  }

  return 0;
}