Cod sursa(job #2514025)

Utilizator tomaionutIDorando tomaionut Data 24 decembrie 2019 13:12:38
Problema Carte2 Scor 100
Compilator cpp-64 Status done
Runda Arhiva ICPC Marime 0.47 kb
#include <bits/stdc++.h>

using namespace std;

ifstream fin("carte2.in");
ofstream fout("carte2.out");
int t,a,b,c,d,e;
int main()
{
    fin >> t;
    while (t)
    {
        fin >> a >> b >> c >> d >> e;
        if (a<c and (b<d or b<e)) fout << "posibil\n";
        else if (a<d and (b<c or b<e)) fout << "posibil\n";
        else if (a<e and (b<c or b<d)) fout << "posibil\n";
        else fout << "imposibil\n";
        t--;
    }


    return 0;
}