func_code_string: #include <bits/stdc++.h>   using namespace std;   int n, m, b, mod;   int a[505];   int dp[505][505];   int main() {     scanf( %d%d%d%d , &n, &m, &b, &mod);     for (int i = 1; i <= n; ++i) scanf( %d , a + i);     dp[0][0] = 1;     for (int i = 1; i <= n; ++i) {       for (int j = 1; j <= m; ++j) {         for (int k = a[i]; k <= b; ++k) {           dp[j][k] += dp[j - 1][k - a[i]];           if (dp[j][k] >= mod) dp[j][k] -= mod;         }       }     }     int ans = 0;     for (int i = 0; i <= b; ++i) {       ans += dp[m][i];       if (ans >= mod) ans -= mod;     }     printf( %d n , ans);   }   