in reply to unGodly problems with pop()

Sounds like you're on the right track. You are using strict, aren't you? Perhaps you have a typo. This program:
use strict; my $rest = 'a b c d password'; my @rest = split(/ /, $rest); print "\@rest=@rest\n"; my $apass = pop @rest; print "PASS: $apass\n"; print "\@rest=@rest\n";
produces:
@rest=a b c d password PASS: password @rest=a b c d

update: And maybe you have a space at the end of your scalar, and so the last element is empty. You may want to print out the scalar first with something around it like print "($rest)\n" so you can see it.