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

import "fmt"

type SampleStruct struct {
	Id int64
	Name string
}

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


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