func_code_string: #include <bits/stdc++.h>   using namespace std;   long long n, m, dp[1 << 21], b, ans = 3e18;   pair<long long, pair<long long, long long> > a[1 << 21];   int main() {     cin >> n >> m >> b;     for (long long i = 0, m, x; i < n; i++) {       cin >> a[i].second.first >> a[i].first >> m;       while (m--) cin >> x, x--, a[i].second.second += 1 << x;     }     for (long long i = 0; i < (1 << m); i++) dp[i] = ans;     dp[0] = 0, sort(a, a + n);     for (long long i = 0; i < n; i++) {       for (int j = 0; j < (1 << m); j++)         dp[j] = min(dp[j], dp[j & (j ^ a[i].second.second)] + a[i].second.first);       ans = min(ans, dp[(1 << m) - 1] + a[i].first * b);     }     cout << (ans < (long long)3e18 ? ans : -1);     return 0;   }   