RosettaCodeData/Task/Binary-digits/Lambdatalk/binary-digits-2.lambdatalk
2023-07-01 13:44:08 -04:00

11 lines
278 B
Text

1) we add to the lambdatalk's dictionary the Javascript primitive "dec2bin"
{script
LAMBDATALK.DICT["dec2bin"] = function() {
return Number( arguments[0].trim() ).toString(2)
};
}
2) we use it in the wiki page:
'{S.map dec2bin 5 50 9000}
-> 101 110010 10001100101000
}