Go: package main

import (
	"bufio"
		"os"
	"strings"
	"strconv"
	"fmt"
	"math"
)

var scanner = bufio.NewScanner(os.Stdin)

type Point struct {
	x, y float64
}
func main() {
	for scanner.Scan() {
		buf1 := strings.Split(scanner.Text(), " ")
		line1 := make([]float64, len(buf1))
		for i := range line1 {
			line1[i], _ = strconv.ParseFloat(buf1[i], 64)
		}
		if line1[0] == 0 && line1[1] == 0 &&
			line1[2] == 0 && line1[3] == 0 {
				break
		}
		scanner.Scan()
		buf2 := strings.Split(scanner.Text(), " ")
		line2 := make([]float64, len(buf2))
		for i := range line2 {
			line2[i], _ = strconv.ParseFloat(buf2[i], 64)
		}
		scanner.Scan()
		buf3 := strings.Split(scanner.Text(), " ")
		line3 := make([]float64, len(buf3))
		for i := range line2 {
			line3[i], _ = strconv.ParseFloat(buf3[i], 64)
		}
		if !intersect(line1[0], line1[1], line1[2], line1[3], line2[0], line2[1], line2[2], line2[3]) ||
			!intersect(line2[0], line2[1], line2[2], line2[3], line3[0], line3[1], line3[2], line3[3]) ||
			!intersect(line3[0], line3[1], line3[2], line3[3], line1[0], line1[1], line1[2], line1[3]) {
				fmt.Println("kyo")
		} else {
			p1 := intersection(line1[0], line1[1], line1[2], line1[3], line2[0], line2[1], line2[2], line2[3])
			p2 := intersection(line2[0], line2[1], line2[2], line2[3], line3[0], line3[1], line3[2], line3[3])
			p3 := intersection(line3[0], line3[1], line3[2], line3[3], line1[0], line1[1], line1[2], line1[3])
			area := math.Abs((p2.x - p1.x) * (p3.y - p1.y) - (p2.y - p1.y) * (p3.x - p1.x))/2
			if area < 0.00000001 {
				fmt.Println("kyo")
			} else if 1899999.99999999 < area {
				fmt.Println("dai-kichi")
			} else if 999999.99999999 < area {
				fmt.Println("chu-kichi")
			} else if 99999.99999999 < area {
				fmt.Println("kichi")
			} else {
				fmt.Println("syo-kichi")
			}
		}
	}
}

func cross(x1, y1, x2, y2 float64) int {
	z :=  x1 * y2 - y1 * x2
	if 0 < z {
		return 1
	} else if z < 0 {
		return -1
	} else {
		return 0
	}
}

func intersect(x1, y1, x2, y2, x3, y3, x4, y4 float64) bool {
	if 0 <= cross(x2-x1, y2-y1, x3-x1, y3-y1) *
		cross(x2-x1, y2-y1, x4-x1, y4-y1) {
			return false
	}
	if 0 <= cross(x4-x3, y4-y3, x1-x3, y1-y3) *
		cross(x4-x3, y4-y3, x2-x3, y2-y3) {
			return false
	}
	return true
}

func intersection(x1, y1, x2, y2, x3, y3, x4, y4 float64) Point {
	if x3 == x4 {
		x1, x3 = x3, x1
		y1, y3 = y3, y1
		x2, x4 = x4, x2
		y2, y4 = y4, y2
	}
	ret := Point{}
	if x1 == x2 {
		// y軸に平行な直線の場合
		c := (y4 - y3) / (x4 - x3)
		d := y3 - c * x3
		x := x1
		y := c * x + d
		ret.x, ret.y = x, y
	} else {
		a := (y2 - y1) / (x2 - x1)
		b := y1 - a * x1
		c := (y4 - y3) / (x4 - x3)
		d := y3 - c * x3
		x := (d - b) / (a - c)
		y := a * x + b
		ret.x, ret.y = x, y
	}
	return ret
}

C++: #include <algorithm>
#include <cctype>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <functional>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <string>
#include <vector>

using namespace std;

#define reps(i,f,n) for(int i=f; i<int(n); ++i)
#define rep(i,n) reps(i,0,n)

typedef long long ll;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef pair<int, int> pii;

const double EPS = 1e-10;

typedef complex<double> P;
double cross(const P& a, const P& b){
	return imag(conj(a)*b);
}
double dot(const P& a, const P& b){
	return real(conj(a)*b);
}

struct L : public vector<P> {
	L(){}
	L(const P& a, const P& b){
		push_back(a);
		push_back(b);
	}
};

int ccw(P a, P b, P c)
{
	b -= a;
	c -= a;
	if(cross(b,c) > 0)  return  1;
	if(cross(b,c) < 0)  return -1;
	if(dot(b,c)   < 0)  return  2;
	if(norm(b)<norm(c)) return -2;
	return 0;
}

bool intersectSS(const L& s, const L& t) {
	return ccw(s[0], s[1], t[0]) * ccw(s[0], s[1], t[1]) <= 0 &&
		   ccw(t[0], t[1], s[0]) * ccw(t[0], t[1], s[1]) <= 0;
}

bool crosspoint(const L& l, const L& m, P& out) {
	if(!intersectSS(l, m))
		return false;
	
	double A = cross(l[1]-l[0], m[1]-m[0]);
	double B = cross(l[1]-l[0], l[1]-m[0]);
	if(abs(A) < EPS && abs(B) < EPS)
		return false;
	out = m[0] + B/A*(m[1]-m[0]);
	return true;
}


int main()
{
	for(;;){
		L s[3];
		rep(i, 3){
			int x1, y1, x2, y2;
			scanf("%d%d%d%d", &x1, &y1, &x2, &y2);
			if(!x1 && !y1 && !x2 && !y2)
				return 0;
			s[i].push_back(P(x1, y1));
			s[i].push_back(P(x2, y2));
		}
		
		P p[3];
		bool ok = true;
		rep(i, 3){
			if(!crosspoint(s[i], s[(i+1)%3], p[i])){
				ok = false;
				break;
			}
		}
		
		double area = 0.0;
		if(ok){
			area = abs(cross(p[1]-p[0], p[2]-p[1])/2.0);
		}
		if(area >= 1900000.0)
			puts("dai-kichi");
		else if(area >= 1000000.0)
			puts("chu-kichi");
		else if(area >= 100000.0)
			puts("kichi");
		else if(area >= EPS)
			puts("syo-kichi");
		else
			puts("kyo");
	}
	return 0;
}

C++: #include<iostream>
#include<cstdio>
#include<algorithm>
#include<climits>
#include<string>
#include<vector>
#include<list>
#include<map>
#include<set>
#include<cmath>
#include<queue>
#include<cstring>
#include<stack>
using namespace std;
#define EPS 1e-10

struct Point{
    double x,y;
    Point(){}
    Point(double _x,double _y){
        x=_x; y=_y;
    }
    Point operator +(const Point p)const{
        return Point(x+p.x,y+p.y);
    }
    Point operator -(const Point p)const{
        return Point(x-p.x,y-p.y);
    }
	Point operator *(const double d)const{
		return Point(x*d,y*d);
	}
};

struct Line{
    Point a,b;
    Line(){}
    Line(Point _a,Point _b){
        a=_a; b=_b;
    }
};

double dot(Point p,Point q){
    return p.x*q.x+p.y*q.y;
}

double cross(Point p,Point q){
    return p.x*q.y-q.x*p.y;
}

int ccw(Point a,Point b,Point c){
    if(cross(b-a,c-b)>0) return +1;
    if(cross(b-a,c-b)<0) return -1;
    return 0;
}

bool pss(Line l,Line m,Point &p){
	Point a1,a2,b1,b2;
	a1 = l.b-l.a; a2 = m.b-m.a;
	b1 = m.a-l.a; b2 = m.b-l.a;
	double s1,s2;
	s1 = abs(cross(a1,b1)); s2 = abs(cross(a1,b2));
	if(s1<EPS && s2<EPS) return false;
	if(s1<EPS) swap(s1,s2);
	p = Point(m.a.x+a2.x*s1/(s1+s2),m.a.y+a2.y*s1/(s1+s2));
	if(p.x<min(l.a.x,l.b.x) || max(l.a.x,l.b.x)<p.x ||
	   p.y<min(m.a.y,m.b.y) || max(m.a.y,m.b.y)<p.y)
		return false;
	return true;
}

int main(){
	Line l[3];
	while(true){
		for(int i=0;i<3;i++){
			cin>>l[i].a.x>>l[i].a.y>>l[i].b.x>>l[i].b.y;
			if(l[i].a.x==0 && l[i].a.y==0 && l[i].b.x==0 && l[i].b.y==0) return 0;
		}
		Point p[3];
		bool kyo = false;
		for(int i=0;i<3;i++){
			if(pss(l[i],l[(i+1)%3],p[i])==false) kyo = true;
		}
		if(kyo==true){
			puts("kyo"); continue;
		}
		double s = abs(cross(p[1]-p[0],p[2]-p[0])/2);
		if(s<EPS) puts("kyo");
		else if(s<100000) puts("syo-kichi");
		else if(s<1000000) puts("kichi");
		else if(s<1900000) puts("chu-kichi");
		else puts("dai-kichi");
	}
    return 0;
}