Functions Example 2

use std::fmt::Display;

fn main() {

    tell_me(year_of_birth);    

    tell_me(birthday);    
}

fn tell_me<T: ?Sized + Display>(f: fn() -> &'static T) {

    println!("{}", f());
}

fn year_of_birth() -> &'static i32 {
    
    &2015
}

fn birthday() -> &'static str {
    "May 15, 2015"
}