use std::io; use std::str::FromStr; use std::str::Chars; use std::i32; use std::u8; use std::f64; use std::ascii::AsciiExt; use std::collections::HashMap; use std::collections::HashSet; use std::collections::BTreeMap; use std::collections::BTreeSet; use std::collections::VecDeque; use std::io::prelude::*; use std::time::Duration; use std::cmp; macro_rules! println_stderr( ($($arg:tt)*) => { { let r = writeln!(&mut ::std::io::stderr(), $($arg)*); r.expect("failed printing to stderr"); } } ); macro_rules! print_stderr( ($($arg:tt)*) => { { let r = write!(&mut ::std::io::stderr(), $($arg)*); r.expect("failed printing to stderr"); } } ); fn main() { let v = next_ints(); let (mut a,b) : (f64,f64) = (v[0] as f64,v[1] as f64); let mut num = 0.0; while a >= b { num += (2.0_f64 * f64::consts::PI / f64::asin(b/(a-b))).trunc(); a -= 2.0 * b; } println!("{}",match num as i64 { n if n % 2 == 0 => "K", _ => "S", }) } #[allow(dead_code)] fn next_string() -> String { let mut input = String::new(); io::stdin().read_line(&mut input).unwrap(); input } #[allow(dead_code)] fn next_strings() -> Vec { let input = next_string(); input.split_whitespace().map(|x| x.parse().unwrap()).collect() } #[allow(dead_code)] fn next_int() -> i64 { let input = next_string(); i64::from_str(input.trim()).unwrap() } #[allow(dead_code)] fn next_ints() -> Vec { let input = next_string(); input.split_whitespace().map(|x| x.parse().unwrap()).collect() }