The Kap Programming Language
10 months ago
- #programming
- #graphics
- #interpreter
- Kap interpreter supports bigints, demonstrated by calculating 2 to the power of 300.
- Division of integers in Kap results in rational numbers, showcased by dividing 2 by numbers 1 to 10.
- Three display modes for rational numbers: normal, fancy, or decimal, selectable via the ]radmode command.
- Graphics example: Drawing a circle using complex numbers and their absolute values.
- Basic animation is possible in Kap, demonstrated with an example involving sine functions for movement.
- Implementation of Conway’s Game of Life, including initial setup and loop for continuous iteration.
- Charting capabilities include line, bar, and pie charts, with examples provided for each.
- Simulation of die rolls and histogram plotting to visualize outcomes.
- Sound playback functionality, using sine waves to generate audio samples.
- Simple implementation of the game 2048, with commands for directional moves.