This page is still under construction.

Parts of this page are still being built. What you see may change.

Stone Game 7

Time limit1sMemory limit128 MB

Summary
Two players alternately remove a power of four stones from the pile, and the program reports the winner when both play perfectly.
Level

Medium5 of 10

Topics
Game theory, Math
Solved
No attempts yet

Problem

The stone game is played by two people who take stones in alternating turns.

There are NN stones on the table. Sang-Keun and Chang-Young take turns, and on one turn a player takes exactly 4x4^x stones. Here xx is an integer with x≥0x \ge 0, so the possible counts are 1, 4, 16, 64, and so on. The player who has no legal way to take stones on their turn loses the game.

Both players play perfectly. Write a program that finds the winner. Sang-Keun starts the game.

Input

The first line contains the number of stones NN. (1≤N≤1,000,000,000,0001 \le N \le 1{,}000{,}000{,}000{,}000)

Output

Print SK if Sang-Keun wins the game, or CY if Chang-Young wins.

Examples1

  1. Example 1

    Input
    3
    
    Expected output
    SK