#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for(int i = 0; i < n; ++i)
#define rep2(i, a, b) for(int i = (a); i <= (b); ++i)
#define ll long long

// q / p
struct frac {
    template <typename T> static constexpr inline T gcd(const T a, const T b) { return (b == 0) ? a : gcd(b, a % b); }
    ll q, p;
    inline constexpr void simplify() {
        if(p < 0) {
            p *= -1;
            q *= -1;
        }
        ll g = gcd(q < 0 ? -q : q, p);
        if(g) {
            p /= g;
            q /= g;
        }
    }
    constexpr frac(ll q = 0, ll p = 1) noexcept : q(q), p(p) { simplify(); }

    constexpr bool operator<(const frac &r) const { return q * r.p < p * r.q; }
    constexpr bool operator>(const frac &r) const { return q * r.p > p * r.q; }
    template <class T> const bool operator<(const T &r) const { return *this < frac(r); }
    template <class T> const bool operator>(const T &r) const { return *this > frac(r); }
    constexpr bool operator!=(const frac &r) const { return q * r.p < p * r.q; }
    constexpr bool operator==(const frac &r) const { return q * r.p == p * r.q; }
    constexpr frac operator+(const frac r) const noexcept { return frac(*this) += r; }
    constexpr frac operator-(const frac r) const noexcept { return frac(*this) -= r; }
    constexpr frac operator*(const frac r) const noexcept { return frac(*this) *= r; }
    constexpr frac operator/(const frac r) const noexcept { return frac(*this) /= r; }
    constexpr frac &operator+=(const frac &r) noexcept {
        ll g = gcd(p, r.p);
        q = r.p / g * q + p / g * r.q;
        p = p / g * r.p;
        (*this).simplify();
        return *this;
    }
    constexpr frac &operator-=(const frac &r) noexcept {
        ll g = gcd(p, r.p);
        q = r.p / g * q - p / g * r.q;
        p = p / g * r.p;
        (*this).simplify();
        return *this;
    }
    constexpr frac &operator*=(const frac &r) noexcept {
        q *= r.q;
        p *= r.p;
        (*this).simplify();
        return *this;
    }
    constexpr frac &operator/=(const frac &r) noexcept {
        q *= r.p;
        p *= r.q;
        (*this).simplify();
        return *this;
    }

    void print() {
        long double tmp = (long double)q / (long double)p;
        cout << tmp;
    }
};
ostream &operator<<(ostream &os, frac r) {
    os << r.q << " " << r.p;
    return os;
}

struct Triangle {
    vector<vector<frac>> a;
    Triangle() : a(3, vector<frac>(2)) {}
    vector<frac> &operator[](int k) { return a[k]; }
};
Triangle A, B;
int ans;
using Point = vector<frac>;
struct Line {
    Point a, b;
};
frac tangent(Point a, Point b) { return (a[0] - b[0]) / (a[1] - b[1]); }
frac cross(Point a, Point b) { return a[0] * b[1] - a[1] * b[0]; }
Point operator+(Point a, Point b) { return Point{a[0] + b[0], a[1] + b[1]}; }
Point operator-(Point a, Point b) { return Point{a[0] - b[0], a[1] - b[1]}; }
Point operator*(Point a, frac x) {
    a[0] *= x, a[1] *= x;
    return a;
}
Point crosspoint(Line a, Line b) {
    frac x = cross(a.a - a.b, b.a - b.b);
    frac y = cross(a.a - a.b, a.a - b.b);
    if(x == frac(0) and y == frac(0)) return b.b;
    return b.b + (b.a - b.b) * (y / x);
}

int get(Triangle &a) {
    int res = 0;
    rep(i, 3) rep(j, 3) res += a[i] == B[j];
    return res;
}
void solve(Triangle t, int cnt) {
    int ua[3] = {}, ub[3] = {};
    rep(i, 3) rep(j, 3) if(t[i] == B[j]) ua[i] = ub[j] = true;
    if(accumulate(ua, ua + 3, 0) == 3) {
        ans = min(ans, cnt);
        return;
    }
    rep(i, 3) {
        rep(j, 3) {
            if(ua[i] or ub[j]) continue;
            vector<int> v = {0, 1, 2};
            v.erase(v.begin() + i);
            if(tangent(t[v[0]], t[v[1]]) == tangent(t[i], B[j])) {
                Triangle nxt = t;
                nxt[i] = B[j];
                assert(get(nxt) > get(t));
                solve(nxt, cnt + 1);
            } else {
                rep(k, 2) {
                    auto nxt = t;
                    if(ua[v[k]]) continue;
                    if(tangent(t[v[k ^ 1]], t[v[k ^ 1]] + B[j] - t[i]) == tangent(t[v[k]], t[v[k]] + t[i] - t[v[k ^ 1]])) continue;
                    nxt[v[k]] = crosspoint(Line{t[v[k ^ 1]], t[v[k ^ 1]] + B[j] - t[i]}, Line{t[v[k]], t[v[k]] + t[i] - t[v[k ^ 1]]});
                    // assert(tangent(nxt[v[0]], nxt[v[1]]) == tangent(nxt[i], B[j]));
                    nxt[i] = B[j];
                    assert(get(nxt) > get(t));
                    solve(nxt, cnt + 2);
                }
            }
        }
    }
    return;
}
main() {
    while(1) {
        rep(i, 3) rep(j, 2) cin >> A[i][j].q, A[i][j].p = 1;
        if(cin.fail()) return 0;
        rep(i, 3) rep(j, 2) cin >> B[i][j].q, B[i][j].p = 1;
        ans = 5;
        solve(A, 0);
        if(ans == 5)
            cout << "Many\n";
        else
            cout << ans << endl;
    }
}


Measured memory_bytes: 3104