my $mask= 0x0f000007; my $val= $mask; do { printf "0x%08.8x\n", $val; --$val; $val &= $mask; } while( $val != $mask );
- tye
In reply to Re: Incrementing only the masked bits (sure)
by tye
in thread Incrementing only the masked bits
by lyeoh
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |