import java.io.*; import java.util.*; public class Main_yukicoder524 { private static Scanner sc; private static Printer pr; private static void solve() { long n = sc.nextLong(); long ret = 0; if (n < 1_000_000) { // if (n < 10) { for (int i = 1; i <= n; i++) { ret ^= i; // pr.printf("%d %d\n", i, ret); } } else { for (int i = 1; true; i++) { long tmp = (0x1L << i + 1) - 1; if (tmp >= n) { n -= (0x1L << i) - 1; if (n % 4 == 0) { ret = 0; } else { ret = 1; } break; } } } if (ret != 0) { pr.println("O"); } else { pr.println("X"); } } // --------------------------------------------------- public static void main(String[] args) { sc = new Scanner(System.in); pr = new Printer(System.out); solve(); pr.close(); sc.close(); } private static class Printer extends PrintWriter { Printer(PrintStream out) { super(out); } } }