Friday, Jan 19th

Last update12:59:40 PM GMT

Find the next closest multiple of 8 using bitwise operations

Write e-mail

int nextmultipleof8 (int input)

argaiv1077

{

input >>=3;

input ++;

input <<=3;

return input;

}

Share this post



Web Hosting