NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
TIMTOWTDI in action and $A++ (Score:1)
use the award-winning Inline module (Score:1)
int one_plus_one() {
return 1 + 1;
}
EOC
print one_plus_one();
We are Perl. Your table will be assimilated. Surrender your beer. Resistance is futile.
pid nastiness (Score:1)
Ideas for solutions (Score:1)
Write the binary logic by hand using and (&), or (|), xor (^), shifts (<<, and >>), and simple loops.
Go wacky with Roman numerals.
Other wacky code snippets:
"1+"+"+1"
"1+1"+"1+1"
$\=$/;"1+1"=~/(.)[+](.)/; print $++$+;
print print."+".print."=".((print)+(print))."\n";
Gotta love recursion (Score:1)
my $one_plus_one = sum(ceil(rand), cos());
sub sum {
@_ && (shift)- -sum(@_);
}
btw - this code will fail to produce a correct answer every once in a while
store the data in the program (Score:1)
Oh, for a CODE tag like on PerlMonks...
Re:store the data in the program (Score:1)
CODE? You mean like this?
my $val;
sysseek(DATA, -10, 2);
sysread(DATA, $val, 1);
$val += $val;
print "$val\n";
1
__END__
Re:store the data in the program (Score:1)
pudge, you're my hero once again.