From b4fe567f2d4719c180eb24fb753b68cd62d06cef Mon Sep 17 00:00:00 2001 From: Jon Lee Date: Tue, 14 May 2024 00:26:30 +0800 Subject: [PATCH] test commmit --- Go_tutorial.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Go_tutorial.md b/Go_tutorial.md index 86ba75e..f50ae3b 100644 --- a/Go_tutorial.md +++ b/Go_tutorial.md @@ -80,6 +80,7 @@ There are three kinds of way to initialize variables: var v1 int = 10 // method 1 var v2 = 10 // method 2 v3 := 10 // method 3 +v4 := [3]int{1, 2, 3} //initialize a slice ``` It can be observed that complier can deduce the data type automatically. However, when we use **method 3**, the variable should not be declared before, which will contibute to the error.