#include #include #include #include #include #include #include #include #include #include #include using namespace std; using ll = long long int; #define chmax(x,y) x = (x > (y)) ? x : (x = (y)); #define chmin(x,y) x = (x < (y)) ? x : (x = (y)); int main(int argc, char const *argv[]) { vector> dp(101,vector(1001,0)); int N; cin >> N; vector W(N); for(auto &e :W)cin >> e; dp[0][0] = 1; for(int i=0;i= 0)dp[i+1][j-W[i]] = 1; } } } if(dp[N][0])std::cout << "possible" << std::endl; else std::cout << "impossible" << std::endl; }