SteemJs/dSteem Code Editor

This page loads Steem-Js (v0.7.7) and dSteem (v0.8.6). The log() can be used to print to the page console. You can also press F12 for your browser console i.e. console.log() etc. Use Ctrl + [ or ] to indent your JS code.

URL Parameter s code, eg.: ?s=//steemjs%0Alog("Hello,%20SteemJs!")


const hamming_distance = (a, b) => {
    let d = 0;
    let h = a ^ b;
    while (h > 0) {
        d ++;
        h &= h - 1;
    }
    return d;
}

log(hamming_distance(5, 6));
$('#nodes'):

View Other Steem Tools and APIs | Vote @justyy a Witness or Set @justyy as Proxy

URL parameter: ?nocache

Created and Maintained by @justyy. All rights Reserved ©, 2024. 中文: SteemJs 测试工具