June 2018 Update
This commit is contained in:
parent
ba8067c3b7
commit
22f33d4004
5278 changed files with 84726 additions and 14379 deletions
7
Task/Binary-digits/Red/binary-digits.red
Normal file
7
Task/Binary-digits/Red/binary-digits.red
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
Red []
|
||||
|
||||
foreach number [5 50 9000] [
|
||||
;; any returns first not false value, used to cut leading zeroes
|
||||
binstr: form any [find enbase/base to-binary number 2 "1" "0"]
|
||||
print reduce [ pad/left number 5 binstr ]
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue