Skip to content

Commit 954ae5c

Browse files
committed
feat: add Roc
1 parent b0ea290 commit 954ae5c

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

languages.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,6 @@
112112
"pil": "PicoLisp",
113113
"pilot": "PILOT",
114114
"p8": "Prog8",
115-
"raku": "Raku (formerly Perl 6)",
116115
"phix": "Phix",
117116
"php": "PHP",
118117
"pl": "Prolog",
@@ -126,11 +125,13 @@
126125
"pyth": "Pyth",
127126
"q": "Qore",
128127
"r": "R",
128+
"raku": "Raku (formerly Perl 6)",
129129
"reb": "REBOL",
130130
"rb": "Ruby",
131131
"rexx": "Rexx",
132132
"rkt": "Racket",
133133
"rf": "Ratfor",
134+
"roc": "Roc",
134135
"rs": "Rust",
135136
"s3": "Starset",
136137
"scala": "Scala",

solutions/punishment_roc.txt

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
app [main!] { cli: platform "https://github.com/roc-lang/basic-cli/releases/download/0.19.0/Hj-J_zxz7V9YurCSTFcFdu6cQJie4guzsPMUi5kBYUk.tar.br" }
2+
3+
import cli.Stdout
4+
import cli.Arg exposing [Arg]
5+
6+
punish! = |count|
7+
ret = Stdout.line!("I will not throw paper airplanes in class.")
8+
if count > 1 then
9+
punish!(count - 1)
10+
else
11+
ret
12+
13+
main! : List Arg => Result {} _
14+
main! = |_args|
15+
punish!(500)

0 commit comments

Comments
 (0)