Under construction

Still being built. Things may change

Root Nim Game

Time limit1sMemory limit512 MB

Summary
Given piles of stones, a move replaces a pile of x with any y in [x^(1/4), sqrt(x)] with y < x; determine the winner under optimal play.
Level

Medium7 of 10

Topics
Game theory, Math, Prefix sum
Solved
No attempts yet

Problem

Koosaga and Cubelover are going to play a Root Nim game. The game uses NN piles of stones, and pile ii has AiA_i stones. The two players take turns. On each turn, a player must do the following.

  • Choose one pile. Let xx be the number of stones in that pile.
  • Choose an integer yy that satisfies 0≤y<x0 \le y < x and x1/4≤y≤x1/2x^{1/4} \le y \le x^{1/2}, then change the number of stones in the chosen pile to yy.

A player who cannot make a move loses the game.

Given NN and the number of stones in each pile, write a program that determines who wins. Both players play optimally. Koosaga moves first.

Input

The first line contains the number of piles NN (1≤N≤1000001 \le N \le 100000). The second line contains AiA_i (1≤Ai≤10000000000001 \le A_i \le 1000000000000), the number of stones in each pile.

Output

If Koosaga wins, print "koosaga". If Cubelover wins, print "cubelover".

Examples3

  1. Example 1

    Input
    1
    1
    
    Expected output
    cubelover
    
  2. Example 2

    Input
    2
    1 2
    
    Expected output
    cubelover
    
  3. Example 3

    Input
    10
    1 2 3 4 5 6 7 8 9 10
    
    Expected output
    koosaga