func_code_string: #include <bits/stdc++.h>   using namespace std;   const int Direction[4][2] = {{-1, 0}, {0, 1}, {1, 0}, {0, -1}};   const int Nmax = 303000;   long double n, m;   long double ans = 0;   int main() {     ios_base::sync_with_stdio(0);     cin >> n >> m;     long double r = n * m;     for (int k = 1; k <= min(n, m); k++) {       long double add = 1. * k * k / (long double)n;       for (double i = n - k + 1; i <= n; i++)         add = (add * (long double)(i)) / (long double)(i - n + k);       for (double i = r - m - n + k + 1; i <= r - n; i++)         add = (add * (long double)(i)) / (long double)(i + n - k);       for (double i = 1; i <= k; i++)         add = (add) * (m - k + i) / (long double)(r - k + i);       ans += add;     }     cout.precision(16);     cout << fixed << ans << endl;     return 0;   }   