diff --git a/structs/demo2.go b/structs/demo2.go index ad3af76..0a93a23 100644 --- a/structs/demo2.go +++ b/structs/demo2.go @@ -12,7 +12,12 @@ func (c customer) save() { fmt.Println("Has been added : ", c.firstName, c.lastName,c.age) } +func (c customer) update() { + fmt.Println("Updated : ", c.firstName, c.lastName, c.age) +} + func Demo2() { c:= customer{firstName: "Engin", lastName: "Demiroğ", age: 35} c.save() + c.update() } \ No newline at end of file