The Type of Owned Strings
We'll cover the following...
We'll cover the following...
The type of an owned string is String. You can test this by modifying the program above to have a type annotation, e.g.,
However, when you get a type error, the compiler will usually give you a slightly more verbose name. If I make a mistake and say i32 instead of String, I’ll get this error message: