Rust Programming Tutorial #43 - function shadowing

preview_player
Показать описание
Hey everyone, I started an English series about rust programming. I saw that some points that I consider important were not mentioned in the Rust programming tutorials. As you can see from the video, although I am not a native speaker, I decided that these issues are important for a real Rustacean and should be mentioned. I hope the information in the video will be useful for you.

📄 Resources

📌 Links

▶️ Playlist with this video:

🦀 Timeline:
00:00 - introduction
00:32 - stack and heap difference
01:44 - ownership with the clone() method
02:18 - briefly about ownership
02:45 - function shadowing

🦀 Tags
- rust
- rust-lang
- rust tutorials
- rust not the game
- rust programming tutorial
- learn rust programming
- rust programming language
- rust functions
- rust returning functions

🦀 HashTags
#rustprogramming #rusttutorial2022 #rustprogramminglanguage #rustfunctions
Рекомендации по теме
Комментарии
Автор

What if you just

fn basket(count: &String) {
println!("{}", count)
}

fn main() {
let n = "one".to_string();
basket(&n);
println!("{}", n)
}

dxfate