Skip to content Search Apps Documentation Source Content Run Reset Eval Playground File Folder Download Copy Actions State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

Community realm. Read the code first. Community realm, deployed by its author. Read the code before you interact or send coins.

tally.gno

0.31 Kb · 16 lines
 1package tally
 2
 3import "strconv"
 4
 5var count int
 6
 7// Bump adds one to the tally and returns the new count. Anyone may call it.
 8func Bump(cur realm) int {
 9	count++
10	return count
11}
12
13// Render shows the current count.
14func Render(path string) string {
15	return "# Tally board\n\nCount: " + strconv.Itoa(count) + "\n"
16}