Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,7 @@
class Number {
method ⊕(arg) {
self + arg
}
}
say (21 ⊕ 42)

View file

@ -0,0 +1,20 @@
var colors = Hash(
'black' => "000",
'red' => "f00",
'green' => "0f0",
'yellow' => "ff0",
'blue' => "00f",
'magenta' => "f0f",
'cyan' => "0ff",
'white' => "fff",
)
for color,code in colors {
String.def_method("in_#{color}", func (self) {
'<span style="color: #' + code + '">' + self + '</span>'
})
}
say "blue".in_blue
say "red".in_red
say "white".in_white