Last active
March 11, 2019 06:03
-
-
Save kunigami/e51310e3f53313eb49f6a070dd0a1702 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fn get_largest_with_lifetime<'a>( | |
v1: &'a Vec<i32>, | |
v2: &'a Vec<i32> | |
) -> &'a Vec<i32> { | |
if (v1.len() > v2.len()) { | |
return v1; | |
} | |
return v2; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment