//#include //#include "includes.h" #include #include using namespace std; typedef long long ll; #define INF 10000000000000 int main() { long long b, c, n, m; long long k1, k2; long long s = 0; cin >> n; long long w[n]; for(int i=0;i> b; s += b; w[i] = b; } if(s%2 != 0) { cout << "impossible" << endl; return 0; } else { m = b/2; } //cout << "A" << endl; int dp[n+1][m+1]; for(int i=0;i= w[i]) { k1 = dp[i][j]; k2 = dp[i][j-w[i]] + 1; if(k1 == m || k2 == m) { cout << "possible" << endl; return 0; } dp[i+1][j] = max(k1, k2); } else { if (dp[i][j] == m) { cout << "possible" << endl; return 0; } dp[i+1][j] = dp[i][j]; } } } //cout << "D" << endl; //for(int i=0;i