Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

v0 source realm

Package quizstreak is a multiple-choice trivia quiz where every player runs their own independent streak instead of r...

Readme View source

Quiz Streak

⚠️ Experimental — generated with no human supervision by the daily MCP pipeline to exercise gno tooling. Not audited. See r/moul/x/daily.


A trivia quiz where every player runs their own independent streak instead of racing others for one shared question. Answer correctly and your streak grows, moving you to a fresh question; answer wrong and your streak resets to zero (but the question stays put so you can retry). A global leaderboard ranks addresses by their best-ever streak — call Answer(0-3) to play, or Render your own address to see your live dashboard.

Built for sapphire (gno 0.9). Live demo (agent address): https://sapphire.testnets.gno.land/r/g12cs4cehujpffpjpywmkqj43m6u5ya53nj69sjz/quizstreak


Part of moul/gno-contracts — moul's versioned gno.land contracts. See the repository for the full catalog, build/test tooling, and usage.

Dependency graph:

gno.land/r/moul/x/daily/quizstreak/v0 dependency graph

🧪 Highly experimental — potentially vibe-coded. Not audited; may break, change, or be removed at any time. Do not use with anything of value. Full disclaimer: DISCLAIMER.

Overview

Package quizstreak is a multiple-choice trivia quiz where every player runs their own independent streak instead of racing others for a single shared question.

Each address gets its own current question, picked deterministically from the address and the block height of its first answer so different players don't all start on the same question. A correct answer extends the player's streak and advances them to their next question; a wrong answer breaks the streak back to zero but leaves the same question live so they can retry. The realm tracks each player's best-ever streak on a global leaderboard.

Functions 2

func Answer

crossing Action
1func Answer(cur realm, choiceIdx int) string
source

Answer submits a choice (0..3) for the caller's current question. Crossing function: caller invokes as Answer(cross(cur), choiceIdx).

func Render

1func Render(path string) string
source

Render produces the gnoweb Markdown view. The root path shows the rules and the leaderboard; a path of a bech32 address shows that player's current question and stats.

Imports 5

Source Files 3