Languages Features Creators Calendar CSV Resources Blog About Pricing Add Language
GitHub icon

pyret

pyret - Programming language

< >

pyret is a programming language created in 2011 by Joe Gibbs Politz.

#634on PLDB 12Years Old 1.2kUsers
0Books 0Papers

Pyret is a programming language designed to serve as an outstanding choice for programming education while exploring the confluence of scripting and functional programming. It's under active design and development, and free to use or modify.


Example from the web:
data BinTree: | leaf | node(value, left, right) end fun tree-sum(t): doc: "Calculate the sum of node values" cases (BinTree) t: | leaf => 0 | node(v, l, r) => v + tree-sum(l) + tree-sum(r) end where: tree-sum(leaf) is 0 node4 = node(4, leaf, leaf) tree-sum(node(5, node4, leaf)) is 9 end
Example from hello-world:
print('Hello World')

Language features

Feature Supported Token Example
Strings ✓ '
'Hello world'
Print() Debugging ✓ print
bbc-basic.html · pyret.html · edgedb.html

View source

- Build the next great programming language · Search · v2023 · Day 208 · Docs · Acknowledgements · Traffic · Traffic Today · Mirrors · GitHub · feedback@pldb.com