Created
July 5, 2015 19:48
-
-
Save mfpiccolo/d147c3643b1fe880fa96 to your computer and use it in GitHub Desktop.
Rust reverse example
This file contains hidden or 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 reverse(s: String) -> String { | |
// reverse string here | |
} | |
#[test] | |
fn it_works() { | |
assert!( | |
reverse(“Don’t use palindrome”) == "emordnilap esu t'noD"; | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment