#include #include #include #include #include #include #include #include #include using namespace std; #define mod (1000000000+7) #define N (10007) #define INF 1e16 typedef long long ll; typedef pair P; bool dp[5010][1<<15]; int main(void){ int n; cin>>n; vectora(n); int sum=0; for(int i=0;i>a[i]; } dp[0][0]=true; for(int i=0;i