mpl/examples/02_factorial.mpl
developtheweb@protonmail.com 3cf435b41e Initial commit: Mathematical Programming Language (MPL)
A proof-of-concept parser demonstrating that programming languages can be built
entirely from mathematical notation, enabling cognitive universality in computing.

MPL replaces English keywords with mathematical symbols, making programming
accessible to the 80% of humanity who don't speak English. Every design decision
follows the Fatima Test: "Will this make sense to a 10-year-old who doesn't
speak English?"

Current implementation:
- Complete ANTLR 4 grammar with 70+ mathematical operators
- Parser supporting all major programming paradigms
- Zero grammar ambiguities
- ASCII escape sequences for every Unicode symbol

This release contains:
- Core parser implementation
- Grammar specification
- Example programs
- Comprehensive documentation
- Whitepaper outlining the vision

Note: This is a parser-only proof of concept. Programs can be parsed but not
executed. The interpreter and runtime are future work.
2025-07-26 18:39:08 -04:00

4 lines
No EOL
141 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- Factorial example with proper precedence
factorial ≜ λn∈: (n≤1 ⟹ 1) | (n×factorial(n-1));
result ← factorial(5);
✎result;