19 lines
305 B
Perl
19 lines
305 B
Perl
$encrypted = "AB/uOsC7P93EI";
|
|
|
|
$salt = substr($encrypted, 0, 2);
|
|
|
|
print "Guess the word: ";
|
|
|
|
while(<>) {
|
|
|
|
chomp;
|
|
if ($encrypted eq (crypt $_, $salt)) {
|
|
print "You got it!";
|
|
exit;
|
|
} else {
|
|
print "Nope.\n";
|
|
print "Guess the word: ";
|
|
}
|
|
}
|
|
|
|
|