package brain type State struct { Value int } func (state *State) Set(v int) { state.Value = v } func (state *State) Get() int { return state.Value }