Last active
June 20, 2018 19:33
-
-
Save BrantRoom3327/c614a4e4706eeaa2fb62f484cb0a2434 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
assert_eq!(Some("Andre").unwrap_or("Giant"), "Andre"); // "Andre" | |
assert_eq!(None.unwrap_or("Vizzini"), "Vizzini"); // "Vizzini" | |
//from above | |
assert_eq!(waiting.unwrap_or("Nope"), "I'm Waiting for Vizzini."); // I'm Waiting for Vizzini. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment