From d9fc8106a2fb4bbc28e752f0abc3d98dc152209b Mon Sep 17 00:00:00 2001 From: Maurício Antunes Date: Thu, 13 Apr 2023 19:33:35 -0300 Subject: feat: Add one more structs exercise --- exercises/structs/structs3/main.go | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 exercises/structs/structs3/main.go (limited to 'exercises/structs/structs3') diff --git a/exercises/structs/structs3/main.go b/exercises/structs/structs3/main.go new file mode 100644 index 0000000..ce0d0f7 --- /dev/null +++ b/exercises/structs/structs3/main.go @@ -0,0 +1,17 @@ +// structs3 +// Make me compile! +// +// I AM NOT DONE +package main + +import "fmt" + +type Person struct { + firstName string + lastName string +} + +func main() { + person := Person{firstName: "Maurício", lastName: "Antunes"} + fmt.Printf("Person full name is: %s\n", person.FullName()) // here it must output Person full name is: Maurício Antunes +} -- cgit v1.2.3-70-g09d2