Re: ping Purl Gurl? Beginner Level Perl
- From: Purl Gurl <purlgurl@xxxxxxxxxxxx>
- Date: Sun, 15 Jul 2007 15:33:40 -0700
blmblm wrote:
Purl Gurl wrote:blmblm wrote:
select STDOUT;$|=1;
@v248=(a .. z);@v216=qw(1 11 12 1 11 12 -8
[...]
Ha! Ha! Now ain't you a cute ass!
Surprise! I actually know something!
I am very surprised.
* demure smile *
Now *that*'s acting.
I never act, character role play, charade nor present
false facades. I am always deadpan serious and sincere.
I wasted some time trying to understand how a variable could
be named simply "@" or "$" (contrary to what the man pages [1]
were telling me), before deciding that rather than trying
to understand the code by reading it I should just run it.
Once that worked (sort of), I opened the code in a text editor.
vim in a text-only window didn't do a whole lot better than
trn with the high-ASCII characters, but there were enough
clues ....
My code should print,
purl gurl rocks!
PURL GURL ROCKS!
purl gurl rocks!
However, on a single line with previous text vanishing, then
followed by slow deliberate "typing" of one character at a time.
Much like your code but a bit fancier. This is like someone typing,
backspacing out the text, then typing again, several times.
[1] Is this a term known in the Windows world? Explanation
on request. Or you may have enough exposure to Unix/Linux
to know.
Yes, Man Pages. Those manual pages for Perl are very poorly
written. If you are to learn Perl, buy a couple of beginner
books from O'Reilly. "Learning Perl" and "Perl Cookbook" are
two really great books for a start. You can buy both, used,
on Ebay or at Amazon for really cheap. My suggestion is you
not use the Man Pages, this will only slow you down.
Next time, I expect the first appearing line to actually
"say something" before vanishing and being replaced.
It does. Read the code. Since you're been in Usenetland for
many years, I thought you might be amused by the relationship
between the first line of text and the second.
I want to be sure we are on the same page. This is what
I scraped off my screen before your words vanish,
oyzoyz vf abg fb onq urefrys.
Quite clear there is a one-to-one relationship between
what replaces your text,
blmblm is not so bad herself.
At first, I thought backwards writing but this text flashes
by so quick, I decided to wait and capture. Looks, at a
quick glance, you have shifted by one half of the number
of letters in our alphabet. Moving from "z" to "m" is
an offset of thirteen.
This seems a rather ROTten way to add creativity.
For trivia, you do not need to flush the print buffer
with Perl. Runs fine without your first line.
Maybe on your system [2]. On mine, if I remove that first
line I get different behavior, completely consistent with its
meaning as described in the "perlfunc" man page. Re-read my
description of your program's output.
I am currently running Win XP Pro systems. I need Windows for
all the available programs, not available on *nix machines,
such as my live stock market feed. Making money with my
Windows machines is good motivation for using Win. I also
write a lot, I mean a way lot. I need the graphical word
processors to cut down on my typing time and all that.
[2] It *would* be interesting and useful, however, to know
a little about the environment in which you're running these
programs. My guess is Windows' command shell (command.exe?),
though I could be wrong. It would be completely unsurprising
to me to learn that the Windows command shell and bash (my
current Linux shell) don't behave exactly the same with regard
to buffering of STDOUT. Something that might be interesting --
replace the "1" in that line with a "0" and tell me whether
the program behaves differently in your environment. (It does
in mine.)
Removing the flush, changing from 0 to 1 makes no difference
on a Win machine. Flushing is automatic upon "print" being
encountered. Not true for cgi applications but this is related
to a web server. I run Apache on our machines. Apache will
respond to flush commands, in a sense. Flushing is performed
but a final flush does not happen until the cgi application
ends; all printing flushes at program end.
Right, a command shell. This is truly a DOS emulator. I much like
old MS-DOS usage. My experience dates back to DOS 3.x versions and
Win3.x versions. Prior to this, an O/S known as Deskmate which is
an early Radio Shack brand just before Windows hit big. Deskmate,
if I remember right, this places me back in late Seventies or
early Eighties era. Heck, I was a customer of AOL before this
became known as America Online. I can no longer remember what
AOL was called back then, access was dialup through a local
Radio Shack phone number, 1200 baud. I was a teenager then and we
had our baby girl. I needed something, direly needed something
to take my mind off raising a girl more ornery than me.
Our Deskmate computer, used, enjoyed 768 kilobytes of memory,
expanded, and an operating speed of 4 megaHertz; zoom zoom!
Yes, buffering on your *nix machine behaves different than Win.
However, Windows whoops ass on your puny *nix machine.
--
Purl Gurl
--
So many are stumped by what slips right off the top of my mind
like a man's bad fitting hairpiece.
.
- Follow-Ups:
- Re: ping Purl Gurl? Beginner Level Perl
- From: blmblm
- Re: ping Purl Gurl? Beginner Level Perl
- References:
- Interesting math
- From: Skitt
- Re: ping Purl Gurl? Beginner Level Perl
- From: Purl Gurl
- Re: ping Purl Gurl? Beginner Level Perl
- From: blmblm
- Re: ping Purl Gurl? Beginner Level Perl
- From: Purl Gurl
- Re: ping Purl Gurl? Beginner Level Perl
- From: blmblm
- Interesting math
- Prev by Date: Re: Slightly OT - P.A.Systems, Mangoes, and High-Speed Trains
- Next by Date: Re: Spell chucker
- Previous by thread: Re: ping Purl Gurl? Beginner Level Perl
- Next by thread: Re: ping Purl Gurl? Beginner Level Perl
- Index(es):
Relevant Pages
|