Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

how to concatenate two &str in rust

// using 2 variables
let new_string = format!("{}{}", first_string, second_string);
// using 2 literals
let new_string = format!("{}{}", "first string ", "second string");
 
PREVIOUS NEXT
Tagged: #concatenate #rust
ADD COMMENT
Topic
Name
6+7 =