Skip to content

Instantly share code, notes, and snippets.

@rust-play
Created April 23, 2019 19:01
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rust-play/207e2a3995f485f217125cefa74f1ffd to your computer and use it in GitHub Desktop.
Save rust-play/207e2a3995f485f217125cefa74f1ffd to your computer and use it in GitHub Desktop.
Code shared from the Rust Playground
fn main() {
let s1 = "hello";
let s2 = String::from("hello");
let s3 = String::from("hello");
println!("s1 == s2 => {}", s1 == s2);
println!("s1 == s3 => {}", s1 == s3);
println!("s2 == s3 => {}", s2 == s3);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment