#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c;
  cin >> a >> b >> c;
  int smallest = min(b / 2, c / 4);
  if (a > smallest)
    cout << smallest + smallest * 2 + smallest * 4 << " ";
  else
    cout << a + a * 2 + a * 4 << " ";
  return 0;
}
