Bruce Eckel wouldn't know why to switch from Python to Ruby

C

Chad Perrin

while in python it would be:
class Foo:
def __init__(slf,foo):
slf.foo=foo

Argh. It looks unfinished. It's asymmetrical, and not in a beautiful
way.

It's shorter than the Ruby example, but it makes my eyes bleed. An
episode of The Apprentice is shorter than The Maltese Falcon, too, but
it's a hell of a lot uglier.

. . at least, for my taste.

When I want short code, I write it in Perl.
 
G

gabriele renzi

Jeff Wood ha scritto:
.. be careful, you're gonna bring down the python coding police ...

Although not a physical requirement of the runtime, you named your first
variable in the class method slf ... the python community would eat you
alive for that ...

They prefer ( and *ALL* their docs make sure to tell you over and over )
that the first parameter of the class method be named self.

.. Dive into python and every other tutorial on the topic actually stops to
make sure you understand this ...

I find it humorous ... and a bit retentive ... but, to each their own.

j.

you're absolutely right, but in my defense I can say that I did write
that becuase I feel the need to explicitly name self dumb. I find it ok
to write self.foo but naming the argument is just useless imho.
 
G

gabriele renzi

Chad Perrin ha scritto:
Argh. It looks unfinished. It's asymmetrical, and not in a beautiful
way.

It's shorter than the Ruby example, but it makes my eyes bleed. An
episode of The Apprentice is shorter than The Maltese Falcon, too, but
it's a hell of a lot uglier.

. . at least, for my taste.

When I want short code, I write it in Perl.

de gustibus non est disputandum
 
R

Robert Klemme

Chad said:
Um. Okay?

We Germans say "Über Geschmäcker kann man streiten" - interestingly enough
it's the negated translation of the Latin "You cannot argue about
likings"... :)

robert
 
P

Patrick Hurley

Um. Okay?

Four years of high school (although that was sometime ago now) to the rescu=
e:

In matters of taste there can be no dispute.

Colloquially in English: you say potato, I say potato :)
 
S

Steve Litt

Four years of high school (although that was sometime ago now) to
the rescue:

In matters of taste there can be no dispute.

Colloquially in English: you say potato, I say potato :)

Is de gustibus non est disputandum Italian, Latin or something else?
I can think of many threads I'd like to use that phrase in.

SteveT

Steve Litt
http://www.troubleshooters.com
(e-mail address removed)
 
J

Jeff Wood

------=_Part_10373_20017112.1135353246561
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

latin.

Is de gustibus non est disputandum Italian, Latin or something else?
I can think of many threads I'd like to use that phrase in.

SteveT

Steve Litt
http://www.troubleshooters.com
(e-mail address removed)


--
"Remember. Understand. Believe. Yield! -> http://ruby-lang.org"

Jeff Wood

------=_Part_10373_20017112.1135353246561--
 
P

Paul Duncan

--PpQJECQXld3rh+sr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

* Steve Litt ([email protected]) wrote:
[snipped]
Is de gustibus non est disputandum Italian, Latin or something else?=20
I can think of many threads I'd like to use that phrase in.

Quidquid latine dictum sit, altum viditur. [*]

* I don't know Latin but my buddy Google does.

--=20
Paul Duncan <[email protected]> pabs in #ruby-lang (OPN IRC)
http://www.pablotron.org/ OpenPGP Key ID: 0x82C29562

--PpQJECQXld3rh+sr
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: Digital signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFDse8IzdlT34LClWIRAmZJAKCxdqatLD2iZkbDxSKrBFA/XpwCsACeOAIR
PHwnPDVxoAGv48VltVWZPm0=
=5sKJ
-----END PGP SIGNATURE-----

--PpQJECQXld3rh+sr--
 
A

Alan Garrison

Chad said:
Carpe rubium.

Et tu, Ruby?

Okay, never mind. Forget I said anything. That was really bad.

Quondo Omni Flunkus Utor Ruby

(with apologies to Red Green fans :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,152
Latest member
LorettaGur
Top