diff --git a/examples/arrays/arrays.go b/examples/arrays/arrays.go index 54bff09..010a7e5 100644 --- a/examples/arrays/arrays.go +++ b/examples/arrays/arrays.go @@ -1,5 +1,7 @@ // In Go, an _array_ is a numbered sequence of elements of a -// specific length. +// specific length. In typical Go code, [slices](slices) are +// much more common; arrays are useful in some special +// scenarios. package main diff --git a/examples/arrays/arrays.hash b/examples/arrays/arrays.hash index c04751e..8e1c671 100644 --- a/examples/arrays/arrays.hash +++ b/examples/arrays/arrays.hash @@ -1,2 +1,2 @@ -e71f2d3763eb2950727faa39b90cf1bc037d85fa -TaahifSGSwU +e2bdc11af83f9c6964cfa0e06e4642943b3055ae +bBVikSoZ1Z7 diff --git a/examples/arrays/arrays.sh b/examples/arrays/arrays.sh index 61e3019..76c43f6 100644 --- a/examples/arrays/arrays.sh +++ b/examples/arrays/arrays.sh @@ -7,6 +7,3 @@ get: 100 len: 5 dcl: [1 2 3 4 5] 2d: [[0 1 2] [1 2 3]] - -# You'll see _slices_ much more often than arrays in -# typical Go. We'll look at slices next. diff --git a/examples/slices/slices.go b/examples/slices/slices.go index 914a327..c9335e1 100644 --- a/examples/slices/slices.go +++ b/examples/slices/slices.go @@ -1,5 +1,5 @@ -// _Slices_ are a key data type in Go, giving a more -// powerful interface to sequences than arrays. +// _Slices_ are an important data type in Go, giving +// a more powerful interface to sequences than arrays. package main diff --git a/examples/slices/slices.hash b/examples/slices/slices.hash index 24199a5..e23e052 100644 --- a/examples/slices/slices.hash +++ b/examples/slices/slices.hash @@ -1,2 +1,2 @@ -02c5330eb3ef32a88ca22a5adbded9bd356f89f3 -iLnoIEIxeQ1 +13835b88336e031808f2f3887cd43d0b9d85cad0 +76f4Jif5Z8o diff --git a/public/arrays b/public/arrays index 7a0b707..b333813 100644 --- a/public/arrays +++ b/public/arrays @@ -28,7 +28,9 @@

In Go, an array is a numbered sequence of elements of a -specific length.

+specific length. In typical Go code, slices are +much more common; arrays are useful in some special +scenarios.

@@ -42,7 +44,7 @@ specific length.

- +
package main
 
@@ -164,7 +166,7 @@ structures.

when printed with fmt.Println.

- +
 $ go run arrays.go
@@ -177,18 +179,6 @@ when printed with fmt.Println.

- - -

You’ll see slices much more often than arrays in -typical Go. We’ll look at slices next.

- - - - - - - - @@ -204,7 +194,7 @@ typical Go. We’ll look at slices next.

diff --git a/public/slices b/public/slices index 3780b59..78c327a 100644 --- a/public/slices +++ b/public/slices @@ -27,8 +27,8 @@ -

Slices are a key data type in Go, giving a more -powerful interface to sequences than arrays.

+

Slices are an important data type in Go, giving +a more powerful interface to sequences than arrays.

@@ -42,7 +42,7 @@ powerful interface to sequences than arrays.

- +
package main