跳到主要内容
图灵 OJTURING / ONLINE JUDGE

#F1318. Sweets Game

  • ID: 1324
  • 传统题
  • 2000ms
  • 256MiB
  • 尝试: 0
  • AC · 已通过: 0
  • 教学难度:提高
  • 上传者:
  • 位运算
  • 搜索
  • 动态规划
  • 博弈
  • 模拟
  • 数学
  • 编程与模拟
  • 提高
  • 难度
  • 共享题库
  • Codeforces
  • 英文题面
  • 题目来源
  • 题面语言

Sweets Game

题目描述

E. Sweets Game
time limit per test
3 seconds
memory limit per test
256 megabytes
input
standard input
output
standard output

Karlsson has visited Lillebror again. They found a box of chocolates and a big whipped cream cake at Lillebror's place. Karlsson immediately suggested to divide the sweets fairly between Lillebror and himself. Specifically, to play together a game he has just invented with the chocolates. The winner will get the cake as a reward.

The box of chocolates has the form of a hexagon. It contains 19 cells for the chocolates, some of which contain a chocolate. The players move in turns. During one move it is allowed to eat one or several chocolates that lay in the neighboring cells on one line, parallel to one of the box's sides. The picture below shows the examples of allowed moves and of an unacceptable one. The player who cannot make a move loses.

Karlsson makes the first move as he is Lillebror's guest and not vice versa. The players play optimally. Determine who will get the cake.

Input

The input data contains 5 lines, containing 19 words consisting of one symbol. The word "O" means that the cell contains a chocolate and a "." stands for an empty cell. It is guaranteed that the box contains at least one chocolate. See the examples for better understanding.

Output

If Karlsson gets the cake, print "Karlsson" (without the quotes), otherwise print "Lillebror" (yet again without the quotes).

Examples
Input
  . . .
. . O .
. . O O .
. . . .
. . .
Output
Lillebror
Input
  . . .
. . . O
. . . O .
O . O .
. O .
Output
Karlsson

题目来源:fps-www.educg.net-codeforce-1-2833.xml.zip;FPS 共享题包,题包内第 813 题。保留原作者与原赛事署名。