Rust 有兩種類型的字串:字串切片 (&str) 和 owned string (String)。 我們不會規定您應該何時使用哪一種,但我們會向您展示如何識別和創建它們,以及如何使用它們。
&str
String