🐐 Examples

This commit is contained in:
2026-04-01 14:15:06 +02:00
parent 334f0ea5a4
commit 2f138093e3
8 changed files with 97 additions and 0 deletions

View File

@@ -0,0 +1,17 @@
// Rock, paper, scissors against the computer
CVM FORS
DESIGNA choices VT ["PETRA", "CHARTA", "FORFEX"]
DESIGNA compvter VT FORTIS_ELECTIONIS(choices)
DICE("Choose: PETRA (rock), CHARTA (paper), or FORFEX (scissors)")
DESIGNA player VT AVDI()
DICE("Computer chose:", compvter)
SI player EST compvter TVNC {
DICE("Draw!")
} ALVID SI (player EST "PETRA" ET compvter EST "FORFEX") AVT (player EST "CHARTA" ET compvter EST "PETRA") AVT (player EST "FORFEX" ET compvter EST "CHARTA") TVNC {
DICE("You win!")
} ALVID {
DICE("Computer wins!")
}