RE: Reeses Cup
by swiftone (Curate) on Nov 02, 2000 at 00:38 UTC
|
chomp()!
Or, if you have to share it with a friend,
split and chomp()!
| [reply] |
RE: Reeses Cup
by arturo (Vicar) on Nov 02, 2000 at 00:46 UTC
|
while (<REESESCUP>) {
my $weight += (tr/(peanut butter|chocolate)//);
}
| [reply] [d/l] |
|
|
| [reply] [d/l] |
|
|
Hey, the weight disappears after every bite! I gotta try that. I knew I wanted my body rewritten in Perl -- not only would it be much easier to debug (if I caught a flu bug, for example), but weight disappearing would be the best.
$me{body}=join('+',('slim','svelte','sexy'));
$me{brain}++; # Love those overload operators.
Ah, how wonderful.
=Blue
...you might be eaten by a grue... | [reply] [d/l] |
(redmist) RE: Reeses Cup
by redmist (Deacon) on Nov 02, 2000 at 00:48 UTC
|
open(PACKAGE, package) or die "I WANT CANDY!!!!: $!\n";
dump PACKAGE_CONTENTS_ON_TABLE;
PACKAGE_CONTENTS_ON_TABLE:
splice(@reeses_cup, $chocolate_shell);
chomp @reeses_cup if not $sick_yet;
redmist
redmist.dyndns.org
email::redmist
| [reply] [d/l] |
RE: Reeses Cup
by AgentM (Curate) on Nov 02, 2000 at 00:40 UTC
|
| [reply] |
RE: Reeses Cup
by Fastolfe (Vicar) on Nov 02, 2000 at 00:41 UTC
|
Assuming a suitably set up Cup:
$cup->bite;
&Reeses::Cup::bite($cup);
bite $cup until $cup->is_gone;
A variation on "There's More Than One Way to Do It" which in my opinion is a great answer in of itself.
| [reply] [d/l] |
RE: Reeses Cup
by Adam (Vicar) on Nov 02, 2000 at 01:41 UTC
|
#!perl -w
use strict;
use IO::Handle;
my $Hunger;
my %ReesesCup = (
TheLeft => [ 'Chocolate', 'Peanut Butter', 'Fat' ],
TheRight => [ 'Chocolate', 'Peanut Butter', 'Fat' ],
);
EAT:
for( each %ReesesCup )
{
next if /The/; # Urge is there.
chop( $_->[0] );
chomp( $_->[1] );
chomp( $_->[0] );
ignore( $_->[2] );
}
$Hunger = defined $Hunger ? 'Not after that!' : '';
goto EAT if $Hunger;
sub ignore {} STDOUT->print( 'Yum!' );
| [reply] [d/l] |
|
|
nick:
did that say GOTO?!
| [reply] |
(Guildenstern) RE: Reeses Cup
by Guildenstern (Deacon) on Nov 02, 2000 at 00:42 UTC
|
Candy::Crunch or by bytes and nibbles!
Guildenstern Negaterd character class uber alles! | [reply] |
RE: Reeses Cup©?
by Rydor (Scribe) on Nov 02, 2000 at 20:55 UTC
|
@_=split//,"reesespeanutbuttercup";
print while chomp();
print "\nYum!";
@:::::::((==========Rydor====> | [reply] [d/l] |
RE: Reeses Cup©?
by SamQi (Beadle) on Nov 02, 2000 at 22:16 UTC
|
Okay, I must take a crack at it...
open CUP $reesecup;
while( <CUP> )
{
push @stomach, $_;
}
| [reply] |
RE: Reeses Cup©?
by IoaPetra (Novice) on Nov 04, 2000 at 19:12 UTC
|
sub $newReesesMoment {
my $treat=shift;
my $self={
HUNGRY => 1,
SKINCONDITION => 'fair',
MILKRESERVES => 'good',
};
bless($self,ThisTreatGodMakeItPure);
return $self;
}
$me=ReesesCupFunction->newReesesMoment();
if $me->{HUNGRY} {
unpack($wrapperType,$package);
open(MOUTH, "<+/dev/digestion");
recv($currentReeses, $contentsOfTongue);
print MOUTH $contentsOfTongue;
glob $swallow;
require MilkGlass qw(Lift Tilt Drink SetDown);
close(MOUTH);
$numberOfReesesConsumed++;
}
if ($numberOfReesesConsumed > 35) {
$me->{SKINCONDITION}='acne';
}
$me->VerifyMilkReserves();
if ($package==undef) {
warn $spouse;
} else {
sin($more);
}
Okay, it isn't entirely functional, but that ceased to become my priority.
:)
.:.
Ioa Aqualine Petra'ka | [reply] [d/l] |