use proconio::input; fn main() { input! { n: u64, } let c = n.count_ones(); eprintln!("{:b}", n); println!("{}", c * (c - 1)); }