Newer
Older
01_hello / struct / struct3.go
yhornisse on 1 Oct 2021 214 bytes fix sample
package main

import "fmt"

type SampleStruct struct {
	Id int64
	Name string
}

func (p *SampleStruct) hoge() bool {
	fmt.Println(p.Name)
	return true
}


func main() {
	v1 := SampleStruct{1, "taro"}
	v1.hoge()
}