#include <stdio.h>
#include <iostream>
#include <algorithm>
#include <iomanip>
#include <map>
#include <fstream>
#include <sstream>
#include <math.h>
#include <queue>
#include <stack>

using namespace std;


int xyz[3][5];


bool sennbunn(int x1, int y1, int x2, int y2, int x3, int y3, int x4, int y4){//二つの線分が交差しているか判定する(1,2と3,4)
    int tc=(x1-x2)*(y3-y1)+(y1-y2)*(x1-x3);
    int td=(x1-x2)*(y4-y1)+(y1-y2)*(x1-x4);
    int ta=(x3-x4)*(y1-y3)+(y3-y4)*(x3-x1);
    int tb=(x3-x4)*(y2-y3)+(y3-y4)*(x3-x2);
    
    if((tc*td<=0)&&(ta*tb<=0))return true;
    else return false;
}

bool sankaku_atari(int x1, int y1, int x2, int y2, int ax, int ay, int bx, int by, int cx, int cy){//線分と三角が交差しているか判定
    return sennbunn(x1, y1, x2, y2, ax, ay, bx, by)|sennbunn(x1, y1, x2, y2, ax, ay, cx, cy)|sennbunn(x1, y1, x2, y2, cx, cy, bx, by);
}

bool sankaku_in(int x1, int y1, int x2, int y2, int ax, int ay, int bx, int by, int cx, int cy){//線分が三角の中か判定
    bool a,b;
    a=!sennbunn(x1, y1, ax, ay, bx, by, cx, cy);
    a=a&!sennbunn(x1, y1, bx, by, cx, cy, ax, ay);
    a=a&!sennbunn(x1, y1, cx, cy, ax, ay, bx, by);
    b=!sennbunn(x2, y2, ax, ay, bx, by, cx, cy);
    b=b&!sennbunn(x2, y2, bx, by, cx, cy, ax, ay);
    b=b&!sennbunn(x2, y2, cx, cy, ax, ay, bx, by);
    return a|b;
}

bool sanjigen(){
    bool a,b,c,d,e,f;
    a=sankaku_atari(xyz[0][0], xyz[0][1], xyz[1][0], xyz[1][1], xyz[2][0], xyz[2][1], xyz[3][0], xyz[3][1], xyz[4][0], xyz[4][1]);
    b=sankaku_atari(xyz[0][0], xyz[0][2], xyz[1][0], xyz[1][2], xyz[2][0], xyz[2][2], xyz[3][0], xyz[3][2], xyz[4][0], xyz[4][2]);
    c=sankaku_atari(xyz[0][2], xyz[0][1], xyz[1][2], xyz[1][1], xyz[2][2], xyz[2][1], xyz[3][2], xyz[3][1], xyz[4][2], xyz[4][1]);
    d=sankaku_in(xyz[0][0], xyz[0][1], xyz[1][0], xyz[1][1], xyz[2][0], xyz[2][1], xyz[3][0], xyz[3][1], xyz[4][0], xyz[4][1]);
    e=sankaku_in(xyz[0][0], xyz[0][2], xyz[1][0], xyz[1][2], xyz[2][0], xyz[2][2], xyz[3][0], xyz[3][2], xyz[4][0], xyz[4][2]);
    f=sankaku_in(xyz[0][2], xyz[0][1], xyz[1][2], xyz[1][1], xyz[2][2], xyz[2][1], xyz[3][2], xyz[3][1], xyz[4][2], xyz[4][1]);
    //cout<<a<<b<<c<<d<<e<<f<<endl;
    return (a|d)&&(b|e)&&(c|f);
}

/*
int main(){
    int x1; int y1; int x2; int y2; int x3; int y3; int x4; int y4;
    while(cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3 >> x4 >> y4){
        
        cout<<sennbunn(x1,y1,x2,y2,x3,y3,x4,y4)<<endl;
    }
    
}
*/

int main(){
    
    while(cin>>xyz[0][0]>>xyz[0][1]>>xyz[0][2]){
        cin>>xyz[1][0]>>xyz[1][1]>>xyz[1][2];
        cin>>xyz[2][0]>>xyz[2][1]>>xyz[2][2];
        cin>>xyz[3][0]>>xyz[3][1]>>xyz[3][2];
        cin>>xyz[4][0]>>xyz[4][1]>>xyz[4][2];
        if(sanjigen()){
            cout<<"MISS"<<endl;
        }else{
            cout<<"HIT"<<endl;
        }
        
    }
}