ArkScript is an open source programming language created in 2019 by Alexandre Plateau and Pierre Pharel and Natendrtfm.
#427on PLDB | 5Years Old |
git clone https://github.com/ArkScript-lang/Ark
ArkScript is a small, fast, functional and scripting language for C++ projects
(import std.random)
(import std.Math)
(let number (mod (math:abs (random)) 10000))
(let game (fun () {
(let impl (fun (tries) {
(let guess (toNumber (input "Input a numeric value: ")))
(if (< guess number)
{
(print "It's more than " guess)
(impl (+ tries 1))}
(if (= guess number)
{
(print "You found it!")
tries }
{
(print "It's less than " guess)
(impl (+ tries 1))}))}))
(let tries (impl 0))
(print "You won in " tries " tries.")}))
(game)
(print "Hello World")
Feature | Supported | Example | Token |
---|---|---|---|
Booleans | ✓ | true false | |
Strings | ✓ | "Hello world" | " |
Print() Debugging | ✓ | ||
File Imports | ✓ | (import std.List) (import std.Math :max) | |
Comments | ✓ | # A comment | |
Line Comments | ✓ | # A comment | # |
Semantic Indentation | X |
title | date | score | comments |
---|---|---|---|
Show HN: ArkScript, a small and fast language for scripting video games | 03/26/2020 | 101 | 42 |
Show HN: An Online Playground for ArkScript | 06/16/2024 | 1 | 1 |