Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Spoken Code

by andyf (Pilgrim)
on May 20, 2004 at 22:00 UTC ( #355095=perlmeditation: print w/ replies, xml ) Need Help??

How do you speak your code?

I never grew out of that childish creative habit of inventing my own silly names for things, and I know that all programmers are the same at heart. There's nothing quite like having a good reason to say "bang ping foo bar" a couple of times a day. I think that while we have a common language and superficially similar keyboards and character sets there's a lot of subtlety to how we speak code orally and there are local dialects with their own curious sounds. I mean does anybody actually say "Double Yoo, Double Yoo, Double Yoo" for www anymore? Of course not, round my way its a dubdub.

The character ~ is always a wibble to me. Some people call them twiddles, and I think tilde is the correct name. But 'correct' is hardly well defined in this world where Americans think that # is a pound. It's a hash. Which is why I always thought a good programming syntax would have
#hash = {};
to delcare one.

To help coding we make up names for common symbol combinations. The spaceship operator has to be the coolest, most appropriate I can think of. In the context of qq~ a ~ is a Barney McGroo to me and I am often looking for a missing Cuthbert Dibble Grub ~; (which will only make sense if you're English I think) Similarly a / becomes a wallop, as in hash-bang-wallop #!/

Do you make up your own terminology to help communicate code orally or remember it and do you know any particularly cool or apt ones from your own culture?

Comment on Spoken Code
Select or Download Code
Re: Spoken Code
by mojotoad (Monsignor) on May 20, 2004 at 22:11 UTC
      Nice Matt. I was looking for just a thread like that, seaching under 'spoken' and 'speak'. There's some very odd ones there. That's what I mean about local dialect. You could have a jolly good flame war over that sort of thing I expect. I never ever heard a - called a worm before. One that stands out as obvious and universal is saying 'is' = and 'equals' == to make a very useful distinction. Calling a 'shebang' for #! or 'inc' for ++ is more the sort of thing I'm thinking about, ie how you actually speak your code to coleagues. cheers,
      Andy.
Re: Spoken Code
by gmax (Abbot) on May 20, 2004 at 22:32 UTC

    Being a non-native English speaker, all programming terminology is a foreign language in itself to me. But, OTOH, I remember all English words as a combination of images and letters. Actually, I remember words in any language that way (I also speak French and Spanish). I know that this looks like a terrible waste of storage, but when I speak I am actually recalling the word in my mind before speaking up. Therefore, since speaking code is mostly an exercise of speaking to myself, I don't go beyond the point of depicting the word in my mind, and I can't honestly say what sound I am associating to these concepts.

    There are a few symbols, however, that have a special meaning to me. Long before I touched a computer, I learned to read chess games. Thus, your "#" is a checkmate to me, while "+" is check, "++" is double check, "!" is a strong move, "?" is a weak move, and "+=" means white has a slight advantage.

    (See a more detailed list of symbols in chess notation.)

    Now if anybody had the feeling that geeks are indeed strange fellows, this thread will reinforce such idea considerably. :)

     _  _ _  _  
    (_|| | |(_|><
     _|   
    
      The chess moves is a good one, I dont know that notation, not a chess player, but the earlier influence makes sense, its hard to unlearn and replace symbolic names sometimes. I can't help chevron for the redirects >> :)

      Reading Eriks node, this is fairly redundant I guess. Good to hear some new weird ones though :)
      cheers, Andy.
Re: Spoken Code
by pbeckingham (Parson) on May 20, 2004 at 23:14 UTC

    <Aged-Brit> I could have sworn it was Captain Flack saying Pugh, Pugh, Barley, McGrew, Cuthbert, Dibble, Grub, the famous fireman's rollcall. Watching with mother. </Aged-Brit>

    Update: Nope - I'm wrong. Just found an interview with Brian Cant, whoe had to repeaet the recording for a commercial in the UK. Barney McGrew is correct.

      :) I always thought I heard Barney, because Barney McGrew must be a persons name, and Cuthbert (which is a really esoteric real name) was the other person, Mr. C.D.Grub. Barley eh? Come to think of it, it's just nonsense. The mind of a 4 year old.....
      still. Ah happy memories. cheers,
      Andy.
Re: Spoken Code
by jarich (Curate) on May 21, 2004 at 01:56 UTC
    I'm lazy when it comes to speaking code. I assume that my listener already knows Perl and so I can say what I want my code to achieve rather than worry about specific symbols. This is particularly true when I'm reading code to myself.

    So, to take a simple example:

    while (<>) { s/foo/bah/g; print $_ || "Nothing\n"; }
    I'd say:
    While diamond, substitute foo for bar; globally. Print it or the string Nothing with newline.
    If I really have to spell it out, so to speak, I'd say:
    while diamond, start block.
    ess for'd slash literal foo for'd slash literal bah for'd slash gee, semi-colon.
    print dollar underscore bar bar double quotes literal capital N, nothing; newline. close double quotes, semi-colon.
    close block.

    But I don't often have to spell code out like that.

    I'd pronounce qq~...~; as queue queue tilde <whatever> tidle semi-colon, or preferably double quotes (queue, queue tilde) whatever end quotes.

    # is hash or comment % is percent ! is shriek or bang ^ is caret or hat * is star
    my punctuation pronounciation is rather boring.

    jarich

Re: Spoken Code
by hv (Parson) on May 21, 2004 at 02:43 UTC

    It has an awful lot to do with the person I'm talking to. If I'm looking over my colleague's shoulder - say he's just found out I forgot to implement a method - I'd rattle out something like:

    sub admin, my dollar self equals shift, dollar self to[1] admin or equals do, require NVC DB user, NVC DB User to[1] admin.
    .. and expect him to type (with correct punctuation and indentation):
    sub admin { my $self = shift; $self->{admin} ||= do { require NVC::DB::User; NVC::DB::User->admin; }; }

    Of course, I shall poke fun at him (or possibly a pointed stick) if he fails to do so.

    [1] This is the special one, it is a very distinct word pronounced with a plosive 't' and a vowel sound similar to the French definite article 'le'. I'm not sure how you'd write that phonetically, especially in HTML.

    Hugo

Re: Spoken Code
by etcshadow (Priest) on May 21, 2004 at 03:38 UTC
    The most common shortcut I take when speaking out perl code is leaving off the colon-colon separator in namespaces. Like, just saying "apache DBI" instead of "apache colon colon DBI". If there's potential ambiguity, I'll sound out one colon, but never both. Occasionally one of the pedants I work with will "correct" this, but I don't care... to me it is correct.

    One that actually annoys me is when the more micro$ofty types call a backslash a "whack". Just erks me.

    ------------ :Wq Not an editor command: Wq
      I use the verbal shortcuts as well when telling people things to type on the command line: "cat | grep dash n" instead of "cat | grep space hypen n."

      I also have a (bad?) habit of thinking of | and > as "into," as in "cat myFile | grep foo | wc -l" or "echo 'I Rock! > myFile." In both cases I think "into," and the character that comes out of my fingers is context-dependent (going into a file, or going into another program).

      I've never heard of the "whack" before. That's an interesting one.

      Whack? microsoft-y? Weird. I first heard of whack from other students (way back in the day that I was in college). They were far from being microsoft-y.

      I am neither micro nor soft, thank you very much, but \ to me is "backwhack". Which is odd, because I never use plain "whack" for anything. "forward whack", rarely, if the / is in close proximity to backwhacks. Normally just "slash" or "forward slash", though.

      And I've called * "splat" ever since someone described to me how it looks like a bug hitting a windshield at high velocity. Perl6 will reward this tendency, I believe.

Re: Spoken Code
by hossman (Prior) on May 21, 2004 at 03:53 UTC
    The character ~ is always a wibble to me. Some people call them twiddles, and I think tilde is the correct name.

    I never even noticed that key on my keyboard untill i started college and learned to use unix.

    In Highschool spanish, i was told that a "~" above an "n" was the letter "N-yea" and that the "~" was called a "tilde"

    When i got to college, ever CS professor i had scolded any student who used the term "tilde" by saying:

    That character is a "twiddle" because it exists by itself; if it was above an "n" it would be called something else, and you would be in a class studying a latin language, not a programming language."
Re: Spoken Code
by mstone (Deacon) on May 21, 2004 at 04:28 UTC

    This is moderately famous:

    <> !*''# ^"`$$- !*=@$_ %*<> ~#4 &[]../ |{,,SYSTEM HALTED

    It's a poem -- not Perl poetry, unfortunately -- pronounced:

    Waka waka bang splat tick tick hash, Caret quote back-tick dollar dollar dash, Bang splat equal at dollar underscore, Percent splat waka waka tilde number four, Ampersand bracket bracket dot dot slash, Vertical-bar curly-bracket comma comma CRASH.

    I can't cite the original author, but it certainly isn't me.

      Heh, heh ... that was just lovely.

      That vaguely reminds me of the quote, "Hash! Bang! Bin! Bash!" This is programming? :-)
Re: Spoken Code
by BUU (Prior) on May 21, 2004 at 05:38 UTC
    Americans think that # is a pound. It's a hash.
    Don't be silly. It's an octothorpe.
      From the link Ambrus gave below, it appears to be all our fault anyway, us Bristishers...

      "on British keyboards the £ happens to replace #; thus Britishers sometimes call # on a U.S.-ASCII keyboard ‘pound’, compounding the American error."
      Bloody Britishification.:)
      To be percise Octothrope is the the name invented by a Bell Labs worker for it. At leaset acording to this account.
Re: Spoken Code
by DrHyde (Prior) on May 21, 2004 at 07:53 UTC
Re: Spoken Code
by ambrus (Abbot) on May 21, 2004 at 12:13 UTC
Re: Spoken Code
by halley (Prior) on May 21, 2004 at 17:32 UTC
    From a little script I wrote to "say" code on a text-to-speech announcer. The symbol words are chosen to be single-syllable as much as possible. It can also restore text from the results. I may post the script sometime.
    equate( " \t\r\n", qw(space tab return line) ); equate( '!@#$%^&*+:;', qw(bang at hash buck cent hat and star plus colon semi) ); equate( '<>()[]{}', qw(less more open close elbrack arbrack elbrace arbrace) ); equate( '-=_|', qw(dash is bar pipe) ); equate( '\\/~`\'",.?', qw(hack slash wave tick tock quote comma dot query) ); equate( '0123456789', qw(zero one two three four five six seven eight nine) ); equate( 'abcdefghijklmnopqrstuvwxyz', qw(ay bee see dee ee eff gee aitch eye jay kay ell em en oh pee cue ar ess tee yoo vee dub ecks why zed) );

    --
    [ e d @ h a l l e y . c c ]

Re: Spoken Code - German mixture
by fraktalisman (Hermit) on May 24, 2004 at 21:31 UTC
    Back in the 1980's computer magazines used to print program code so their readers could type it in for themselves. My father and me took turns in reading aloud and typing. Being Germans, we spoke a strange mixture of German and English, like
    "FOR i gleich eins TO zehn: PRINT i: NEXT"
    (FOR I=1 TO 10 : PRINT I : NEXT) - that's Commodore BASIC.
    We didn't pronounce things like colons unless it was ambiguous.

    Now decades later, I still speak (mostly silently) to myself like that when reading or writing perl. Or maybe it's even got worse because of all the abbreviated commands like ~s ...
    "dollar f von dollar param gleich suche Leerzeichen ersetze durch prozent zwanzig, global"
    ( $f{$param}=~s/ /%20/g; )

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlmeditation [id://355095]
Approved by gmax
Front-paged by Caron
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2014-09-02 11:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (22 votes), past polls