Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn valutaPopolarita(ling: &mut String) -> String
- {
- //*ling = "modificata".to_string();
- if ling == "Rust"
- {"in aumento".to_string()}
- else
- {"stabile".to_string()}
- }
- fn main() {
- let mut linguaggio = "Rust".to_string();
- print!("{} ", linguaggio);
- println!("{}", valutaPopolarita(&mut linguaggio));
- let mut s1 = "Occhio al trabocchetto!".to_string();
- let s2 = &mut s1;
- s2.truncate(6);
- println!("{}", s2);
- print!("{}", s1);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement