macro_rules! read_line_to_tuple { ( $( $t:ty ),* ) => {{ let mut input = String::new(); std::io::stdin().read_line(&mut input).unwrap(); let mut iter = input.split_whitespace(); ( $( iter.next().unwrap().parse::<$t>().unwrap() ),* ) }}; } use std::cmp; fn main() { let n = read_line_to_tuple!(usize); let mut ans = 0; for a in 0..=(n / 5) { for b in 0..=cmp::min(a, (n - a * 5) / 2) { if (n - a * 5 - b * 2) % 3 == 0 { ans += 1; } } } println!("{}", ans); }