diff --git a/GO/StringArray.go b/GO/StringArray.go new file mode 100644 index 0000000..0206623 --- /dev/null +++ b/GO/StringArray.go @@ -0,0 +1,18 @@ +package main + +import "fmt" + +func main() { + +// Shorthand declaration of array +arr:= [4]string{"geek", "gfg", "Geeks1231", "GeeksforGeeks"} + +// Accessing the elements of +// the array Using for loop +fmt.Println("Elements of the array:") + +for i:= 0; i < 3; i++{ +fmt.Println(arr[i]) +} + +}