On Fri, 2005-10-21 at 23:07 +0100, Karl Lattimer wrote:
> Except why the toilet seat keeps falling down when someone has one of
> those annoying 'womans' toilets which don't let you balance the seat up.
> That one can have me flumoxed for a good ten minutes.

Duck tape is the universal problem solver.

> One thing that strikes me about all languages is that, after all, they
> are all basically the same. Apart from prolog.

I don't know what your formal education is, but it's amusing how in
university you spend the first 2 years learning some language (it was C
++ for me, which I'd already known; now it's Java), and then in the
third year when you take programming language theory, you're told in the
first class, "by the way, you already know how to program in every
procedural language."  Of course, if you'd paid any attention, you'd
already figured that out much earlier on. :)

So I would revise your statement to say "all procedural languages are
basically the same thing."  Prolog, being a logic language, is
definitely a different beast.  Or functional languages like Scheme.
Learning Scheme has been on my to-do list for far longer than I care to
admit.  One of these days. :)

It annoys the academic in me when I read job descriptions that say "3+
years Java experience required, 2 years C++ experience an asset."  How
about "Knowledge of at least 1 procedural language and a clue about
programming language theory required."  They'd probably get smarter
applicants.

> HTML/CSS aren't even languages, they're just markup pish, there ain't
> logic to them so they aren't languages imho.

HTML and CSS are languages, just not programming languages. :)

> javascript makes my teeth ache like when you hear fingernails on a
> blackboard, yes it works, granted but people insist on writing

As a language, Javascript has its quirks, no doubt.  But as long as you
don't develop any illusions about it, I've found it over all a pleasant
enough language to work with.

> Yes its messier though.

That statement applies equally to all constructs of all languages when
compared to Python. :)

> Oh I get it. hehehe, I'm gonna rewrite freevo with 'this' MWUHAHAHAHA C
> ++ RULES!

Submit that patch.  I double dare you. :)

> You mean at a glance getting the properties/methods of a class via the
> header, i miss this in php too, so i wrote a little perl program to give
> me a list of them.

Python has pydoc to make that job a bit easier.

> so you've got lists, i expect are indexed by number, tuples by text? and
> dictionaries by text in alphabetical order?

"Pepsi?"  "Partial credit."

Tuples and lists are indexed by number.  Dictionaries are indexed by an
arbitrary object.  You can use integers as indexes for dictionaries too,
if you'd like.  But unlike tuples and lists, iterating over a dictionary
is non-deterministic in order.  (So if you require an order, you'd need
to handle that logic explicitly.)

Think of tuples as mini-lists.  Tuples are immutable and light-weight.
Lists are mutable, can be sorted, updated, and so on.

> WHY NOT!!?! Is there an equiv or is that the bit shifting thing that
> confused me a little so I ignored it for now.

a += 1 is equivalent.  Bit shifting works just as it does in other
languages.

> you still see the boundaries, however this doesn't matter in python as
> you all must write the same way!

Well, Python gives you leeway in other areas.  For example, where dischi
would write:

    foo = map(lambda o: o[1], foo)

I would write:

   foo = [ o[1] for o in foo ]


Cheers,
Jason.

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to