Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Yoda Speak Translator

by ChOas (Curate)
on May 02, 2002 at 10:23 UTC ( [id://163496]=note: print w/replies, xml ) Need Help??


in reply to Yoda Speak Translator

Very, VERY cool!!!!

As the master said: "More than one way to do it there is" :
sub yoda { my ($sentence) = @_; my $Pivot=join '|',qw/is be will show do try are teach have/; # Move along, nothing to see here return $sentence unless ($sentence=~/\b$Pivot\b/); # Rearrange our words $sentence="$' $`$&"; # Clear leading spaces and Capitalise $sentence =~ s/^\s+//; $sentence = ucfirst(lc($sentence)); };


GreetZ!,
    ChOas

print "profeth still\n" if /bird|devil/;

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://163496]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2024-03-29 13:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found