Quadratic equation
Children are taught in school to solve quadratic equations, which are equations of the form:
[ ax^2 + bx + c = 0 ]
where (a), (b), and (c) are given real numbers, and (x) is the real number to be determined.
In this problem, you are required to solve a quadratic equation for polynomials with coefficients of zeros and ones, with all operations performed modulo (2).
Given polynomials (a(t)), (b(t)), and (c(t)), find a polynomial (x(t)) such that:
[ a(t)x^2(t) + b(t)x(t) + c(t) = 0 ]
where equality is understood as equality of polynomials. Recall that polynomials are equal if and only if their coefficients at corresponding powers of (t) are equal.
Input
The input file contains polynomials (a(t)), (b(t)), and (c(t)), which are provided by their degrees, followed by coefficients starting from the highest. Zero polynomials in this problem have a degree of (-1). The degrees of all polynomials do not exceed (127). There are two spaces between the highest coefficient and the degree. After a polynomial of degree (-1), there is also one space.
Output
If there is at least one solution to the equation, output any one of them in the same format. The leading coefficient of the found polynomial must not be zero. The degree of the polynomial should not exceed (512).
Otherwise, print "no solution".