#include <cmath>
#include <cstdint>
#include <cstdlib>
#include <iomanip>
#include <ios>
#include <iostream>
#include <utility>

using ll = int64_t;

constexpr ll maxn=50;
ll n;
double m[maxn+5][maxn+5];

void sp(double *a,double* b){
    for(ll i=1;i<=n+1;i++){
        std::swap(a[i],b[i]);
    }
}

void pm(){
    for(ll i=1;i<=n;i++){
        for(ll j=1;j<=n+1;j++){
            std::cout<<m[i][j]<<' ';
        }
        std::cout<<'\n';
    }
    std::cout<<'\n';
}

bool isz(double a){
    if(a > 1e-8 || a<-1e-8){
        return false;
    }

    return true;
}

int main(){
    std::cin>>n;
    for(ll i=1;i<=n;i++){
        for(ll j=1;j<=n+1;j++){
            std::cin>>m[i][j];
        }
    }

    for(ll i=1;i<=n;i++){
        static ll nowused{1};    
        ll maxnj=nowused;
        for(ll j=nowused+1;j<=n;j++){
            if(std::abs(m[j][i])>std::abs(m[maxnj][i])){
                maxnj=j;
            }
        }
        if(isz(m[maxnj][i]))continue;
        else{
            nowused++;
        }
        if(maxnj!=i){
            sp(m[i],m[maxnj]);
        }
        double fact = m[i][i];
        for(ll j=1;j<=n+1;j++){
            m[i][j]/=fact;          
        }
        for(ll k=i+1;k<=n;k++){
            if(k==i)continue;
            double fact = m[k][i];
            for(ll j=1;j<=n+1;j++){
                m[k][j]-=m[i][j]*fact;
            }
        }
    }
    // pm();
    bool isfy=false,isl=false;
    for(ll i=1;i<=n;i++){
        bool isAZ=true;
        for(ll j=1;j<=n;j++){
            if(!isz(m[i][j])){
                isAZ=false;
                break;
            }
        }
        for(ll i=1;i<=n;i++){
            if(std::isnan(m[i][n+1])){
                isl=true;
                return 0;
            }
        }
        if(isAZ){
            if(isz(m[i][n+1])){
                isl=true;
            }else{
                isfy=true;
            }
        }
    }
    if(isfy){
        std::cout<<"-1\n";
        return 0;
    }
    if(isl){
        std::cout<<"0\n";
        return 0;
    }
    for(ll i=1;i<=n;i++){
        std::cout<<std::fixed<<std::setprecision(0)<<"x"<<i<<"="<<std::fixed<<std::setprecision(2)<<m[i][n+1]<<'\n';
    }
}
