aboutsummaryrefslogtreecommitdiffstats
path: root/exercises
diff options
context:
space:
mode:
Diffstat (limited to 'exercises')
-rw-r--r--exercises/slices/slices1/main.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/exercises/slices/slices1/main.go b/exercises/slices/slices1/main.go
new file mode 100644
index 0000000..291f33d
--- /dev/null
+++ b/exercises/slices/slices1/main.go
@@ -0,0 +1,13 @@
+// slices1
+// Make me compile!
+
+// I AM NOT DONE
+package main
+
+import "fmt"
+
+func main() {
+ a := make(, 3, 10) // play with length and capacity
+ fmt.Println("length of 'a':", len(a))
+ fmt.Println("capacity of 'a':", cap(a))
+}