func_code_string: #include <bits/stdc++.h>   using namespace std;   const int N = 260, mo = 777777777;   int f[30][N][N], c[N * 2][N * 2], n, k, ans;   int power(int x, int y) {     int s = 1;     for (; y; y /= 2, x = 1ll * x * x % mo)       if (y & 1) s = 1ll * s * x % mo;     return s;   }   int main() {     scanf( %d%d , &n, &k);     k = n - k;     for (int i = 0; i <= n; i++) c[i][0] = 1;     for (int i = 1; i <= n; i++)       for (int j = 1; j <= i; j++) c[i][j] = (c[i - 1][j] + c[i - 1][j - 1]) % mo;     f[0][0][0] = 1;     for (int i = n; i >= 1; i--)       for (int v = min(22, n / i); v >= 0; v--)         for (int v1 = k; v1 >= 0; v1--)           for (int v2 = n - k; v2 >= 0; v2--) {             int tmp = 1ll * f[v][v1][v2] * c[v1 + v2 + i][i] % mo;             if (v1 + i <= k)               (((f[v + 1][v1 + i][v2]) += (tmp)) >= mo                    ? f[v + 1][v1 + i][v2] -= mo                    : 233);             ;             if (v2 + i <= n - k)               (((f[v + 1][v1][v2 + i]) += (mo - tmp)) >= mo                    ? f[v + 1][v1][v2 + i] -= mo                    : 233);             ;           }     for (int v = 0; v <= min(n, 23); v++)       for (int v2 = 0; v2 <= n - k; v2++)         (((ans) += (1ll * f[v][k][v2] * c[n][k + v2] % mo *                     power(n - v, n - k - v2) % mo)) >= mo              ? ans -= mo              : 233);     ;     printf( %d n , ans);   }   