#include <bits/stdc++.h>
using namespace std;
int main() {
  long long a, b, c, sum = 0;
  cin >> a >> b >> c;
  while (a > 0) {
    if (b / a >= 2 && c / a >= 4) {
      sum = a + 2 * a + 4 * a;
      break;
    }
    a--;
  }
  cout << sum << endl;
}
