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