Pagini recente » Cod sursa (job #3207076) | Cod sursa (job #2143348) | Cod sursa (job #484785) | Cod sursa (job #1245281) | Cod sursa (job #1708910)
#include <iostream>
#include <fstream>
using namespace std;
ifstream fin("carte2.in");
ofstream fout("carte2.out");
int main()
{
int t, a, b, c, d, e, ok;
fin >> t;
while(t--)
{
fin >> a >> b >> c >> d >> e;
ok = 0;
if(a < c && b < d)
ok = 1;
if(a < d && b < c)
ok = 1;
if(a < c && b < e)
ok = 1;
if(a < e && b < c)
ok = 1;
if(a < d && b < e)
ok = 1;
if(a < e && b < d)
ok = 1;
if(ok)
fout << "posibil\n";
else
fout << "imposibil\n";
}
}