การเรนเดอร์th-TH

scribe

Translation status: ภาษาไทย reader-locale proof. Code fences render through the th-TH pipeline; prose is canonical Latin.

Writes a value to standard output.

Syntax: scribe <expression>

Category#

output

Examples#

radix/corpus/nota/nota.fab (canonical · keyword)#

Writes a value to standard output.

# =============================================================================
# scribe — Writes a value to standard output.
# =============================================================================
#
# What this teaches:
#   • Standard output — `scribe` sends values to stdout, the primary output channel.
#   • Expression evaluation — Any expression can be passed, including variables and literals.
#
# Common mistakes:
#   • Confusing scribe (stdout without trailing newline) with nota (diagnostic output with trailing newline).
#
# See also: vide, mone
# =============================================================================

# nota — diagnostic output statements
#
# nota literal-textus
# nota expr
# nota template with § interpolation
# nota labeled template with multiple § placeholders
#
# GRAMMAR:
#   outputStmt :← 'nota' expr (',' expr)*
#
# EXPECTED OUTPUT:
#   nota.expected — greeting, variable, formatted strings, sum, coordinates.

main {
    # Simple string output
    print "Salve, Munde!"

    # Variable output
    const _ nomen  "Marcus"
    print nomen

    # Multiple arguments
    const _ aetas  30
    print "nomen: §"(nomen)
    print "aetas: §"(aetas)

    # Expressions
    const _ x  10
    const _ y  20
    print "summa: §"(x + y)

    # Multiple values in one statement
    print "coordinata: § §"(x, y)
}

Expected output:

Salve, Munde!
Marcus
nomen: Marcus
aetas: 30
summa: 30
coordinata: 10 20