#!/usr/bin/perl -w use strict; sub is_odd { unpack "%1b*", pack "b*", shift } for(1..10) { print is_odd("1" x $_), "\n"; } __END__ 1 0 1 0 1 0 1 0 1 0
Makeshifts last the longest.
In reply to Re: Number of bits, length of RegExp (not a regex)
by Aristotle
in thread Number of bits, length of RegExp
by YAFZ
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |