diff --git a/README.md b/README.md index eabe3f0..41119df 100644 --- a/README.md +++ b/README.md @@ -1280,11 +1280,12 @@ int main(){ var num2 float32 = 3.14 // 不能将其它基本类型强制转换为字符串类型 + // Cannot convert an expression of the type 'float32' to the type 'string' var str2 string = string(num2) fmt.Println(str2) var str3 string = "97" - // 不能强制转换, cannot convert str2 (type string) to type int + // 不能强制转换, cannot convert str3 (type string) to type int var num3 int = int(str3) fmt.Println(num3) }