#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define REP(i,a,b) for(int i=a;i<(int)b;i++) #define rep(i,n) REP(i,0,n) #define all(c) (c).begin(), (c).end() #define zero(a) memset(a, 0, sizeof a) #define minus(a) memset(a, -1, sizeof a) #define minimize(a, x) a = std::min(a, x) #define maximize(a, x) a = std::max(a, x) using ll = long long; int const inf = 1<<29; void ng() { cout << "impossible\n"; exit(0); } void ok() { cout << "possible\n"; exit(0); } int main() { int N; cin >> N; int w[N], sum = 0; rep(i, N) cin >> w[i], sum += w[i]; if(sum % 2) { ng(); } bool dp[101][10001]; zero(dp); dp[0][sum/2] = 1; rep(i, N) for(int j=sum/2; j>=w[i]; j--) { dp[i+1][j] |= dp[i][j]; dp[i+1][j-w[i]] |= dp[i][j]; } if(dp[N][0]) { ok(); } else { ng(); } return 0; }