#include<iostream>
#include<cmath>
using namespace std;
void f(int& a, int& b, int& c, string s) {
int flag = 1, tmp = 0;
for (int i = 0; i < s.size(); i++) {
if (s[i] >= '0' && s[i] <= '9') {
tmp = tmp * 10 + (s[i] - '0');
} else if (s[i] == 'x') {
if (i == 0)tmp = 1;
if (s[i - 1] < '0' || s[i - 1] > '9')tmp = 1;
if (i + 1 < s.size() && s[i + 1] == '^') { //x^2
tmp *= flag;
a += tmp;
tmp = 0;
flag = 1;
i += 2;
} else {
tmp *= flag;
b += tmp;
tmp = 0;
flag = 1;
}
} else {
tmp *= flag;
c += tmp;
tmp = 0;
flag = 1;
}
if (s[i] == '-')flag = -1;
}
if (tmp != 0)c += (tmp * flag);
}
int main() {
string s;
cin >> s;
int a1 = 0, b1 = 0, c1 = 0, a2 = 0, b2 = 0, c2 = 0;
//查x^2
int pos = s.find("=");
string s1 = s.substr(0, pos), s2 = s.substr(pos + 1);
f(a1, b1, c1, s1);
f(a2, b2, c2, s2);
int a = a1 - a2, b = b1 - b2, c = c1 - c2;
// cout<<"a: "<<a<<" b: "<<b<<" c: "<<c<<endl;
if (b * b < 4 * a * c)cout << "No Solution" << endl;
else {
int k = b * b - 4 * a * c;
double end = sqrt((double)k);
double x1 = (0 - (double)b - end) / (2 * (double)a);
double x2 = (-(double)b + end) / (2 * (double)a);
if (x1 < x2) {
printf("%.2f %.2f\n", x1, x2);
} else {
printf("%.2f %.2f\n", x2, x1);
}
}
}