You are viewing a single comment's thread. Return to all comments →
JS
function bitwiseAnd(N, K) { var max = 0; for (var i = 1; i <= N; i++) { for (var j = i + 1; j <= N; j++) { var t = i & j; if (t > max && t < K) { max = t; } } } return max; }
Seems like cookies are disabled on this browser, please enable them to open this website
Day 29: Bitwise AND
You are viewing a single comment's thread. Return to all comments →
JS