https://www.acmicpc.net/problem/16431
using System;
class Program
{
static void Main() {
string[] s=Console.ReadLine().Split(' ');
int br=int.Parse(s[0]),bc=int.Parse(s[1]);
string[] s1=Console.ReadLine().Split(' ');
int dr=int.Parse(s1[0]),dc=int.Parse(s1[1]);
string[] s2=Console.ReadLine().Split(' ');
int lr=int.Parse(s2[0]),lc=int.Parse(s2[1]);
int m=Math.Min(Math.Abs(lr-br),Math.Abs(lc-bc));
int sum=Math.Abs(lr-br)+Math.Abs(lc-bc)-m;
int sum1=Math.Abs(lr-dr)+Math.Abs(lc-dc);
if(sum>sum1) Console.Write("daisy");
else if(sum<sum1) Console.Write("bessie");
else Console.Write("tie");
}
}