func_code_string: #include <bits/stdc++.h>   using namespace std;   using namespace std;   int n, T;   int t[5005];   double p[5005];   double dp[5005][5005];   int main() {     ios::sync_with_stdio(0);     cin.tie(0);     cout.tie(0);     cin >> n >> T;     for (int i = 1; i <= n; i++) cin >> p[i] >> t[i], p[i] *= 0.01;     dp[0][0] = 1;     double ex = 0;     for (int i = 1; i <= n; i++) {       double r = 1.0;       for (int j = 0; j < t[i]; j++) r *= (1.0 - p[i]);       double sum = 0;       for (int j = 1; j <= T; j++) {         sum = sum * (1.0 - p[i]) + dp[i - 1][j - 1];         if (j > t[i]) sum = sum - r * dp[i - 1][j - t[i] - 1];         dp[i][j] = sum * p[i];         if (j >= t[i]) dp[i][j] += r * dp[i - 1][j - t[i]];         ex += dp[i][j];       }     }     cout << setprecision(13) << fixed << ex;   }   