use std::cmp::{max, min}; use std::collections::{HashMap, HashSet, VecDeque}; use std::io::{stdin, stdout, BufWriter}; fn main() { let mut scan = Scanner::default(); let a = scan.next::(); let b = scan.next::(); let ans = (a | b) + (a & b); println!("{}", ans); } #[derive(Default)] struct Scanner { buffer: Vec, } impl Scanner { fn next(&mut self) -> T { loop { if let Some(token) = self.buffer.pop() { return token.parse().ok().expect("Failed parse"); } let mut input = String::new(); stdin().read_line(&mut input).expect("Failed read"); self.buffer = input.split_whitespace().rev().map(String::from).collect(); } } }