AhmedAshraff

Untitled

Feb 12th, 2026
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.52 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2. #define boAshraf ios_base::sync_with_stdio(false); cin.tie(NULL);
  3. #define ll long long
  4. #define sz(s) (int)(s).size()
  5. #define all(s) (s).begin(),(s).end()
  6. using namespace std;
  7. void sol();
  8. int main() {
  9.     boAshraf
  10.     int t = 1;
  11.     cin >> t;
  12.     while (t--) {
  13.         sol();
  14.     }
  15.     return 0;
  16. }
  17.  
  18. void sol() {
  19.     int n,x,y;
  20.     cin>>n>>x>>y;
  21.     if(max(x,y)>n)return void(cout<<"Impossible\n");
  22.     int mx=max(x,y),mn=min(x,y);
  23.     cout<<(2*(mx-1)-mn>n?"Impossible\n":"Possible\n");
  24. }
Advertisement
Add Comment
Please, Sign In to add comment