The Artima Developer Community
Sponsored Link

Weblogs Forum
The departure of the hyper-enthusiasts

262 replies on 18 pages. Most recent reply: Dec 20, 2006 11:11 AM by Carlos Neves

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 262 replies on 18 pages [ « | 1 ... 3 4 5 6 7 8 9 10 11 ... 18  | » ]
Bill de hÓra

Posts: 1137
Nickname: dehora
Registered: May, 2003

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 4:13 PM
Reply to this message Reply
Advertisement
"There is no difference. The terms are synonymous."

Length and Size? Not for anything that has more than 1 dimension.

Bruce Eckel

Posts: 875
Nickname: beckel
Registered: Jun, 2003

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 4:17 PM
Reply to this message Reply
> I still don't understand why self was made mandatory,
> though. I used to think that backward compatibility was
> the reason, but now I'm completely at a loss. The only
> reason I can think of is that this is how we emulated
> classes in C (passing a pointer to this to the function)
> but C++ was already fairly established by then, so it's
> not as if it was a brand new technique.

I think it's because of the "explicit is better than implicit" philosophy. As I've said, I'm probably more ambivalent about this issue than anything else.

> Also, I'm still bothered by the fact that you declare a
> method with n arguments (self being the first one) but
> invoke it with n-1 arguments.

Yes. Slightly non-implicit, that.

> I also dislike how crowded the code becomes when you read
> "self" everywhere, which is very non-pythonic. I like
> significant space indenting for that reason (it saves you
> from all these "end" keywords that I dislike in Ruby) but
> the omnipresence of self ruins a lot for me.

Yes, implicit "this" could be said to gain more than explicit "end" does. It will be interesting to see what happens in Python 3000.

Alex Bunardzic

Posts: 546
Nickname: alexbunard
Registered: Oct, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 4:45 PM
Reply to this message Reply
> "There is no difference. The terms are synonymous."
>
> Length and Size? Not for anything that has more than 1
> dimension.

We're talking collections, such as lists and arrays. How many items do they contain? That's the question that 'length' and 'size' messages are trying to pry out of the collection. Where do you see more than 1 dimension in this scenario?

Dick Ford

Posts: 149
Nickname: roybatty
Registered: Sep, 2003

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 6:05 PM
Reply to this message Reply
Remember, both Tate and Eckel make a living writing and talking about programming technologies. So both have to be looking down the road when Java goes into COBOL-like legacy status. It takes a lot of investment in time to learn a programming language and their libraries well enough to write and lecture about them. So if Ruby "is the one" to make into the enterprise eventually and Python never makes the leap, then that's a huge amount of re-tooling that Eckel has to do. It looks like he's trying to protect his Python investment.

Bruce Eckel

Posts: 875
Nickname: beckel
Registered: Jun, 2003

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 6:07 PM
Reply to this message Reply
> It's not that it's hard to memorize that "size()" gets you
> the List's size, it's more that the fact that array for
> some godawful reason insists on "length" instead of "size"
> is throwing a nice curveball at the unsuspecting coders.

Actually, there is a good point in here -- my guess is that someone on the Java team wasn't communicating with someone else when array was given the read-only length "field" and all the containers use size(). I would have liked Java's array to use size() as well (the compiler could have optimized away the call to produce the same efficiency as length). That would give me fewer things to have to know about, which is what I prefer when programming.

Bruce Eckel

Posts: 875
Nickname: beckel
Registered: Jun, 2003

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 6:12 PM
Reply to this message Reply
> Remember, both Tate and Eckel make a living writing and
> talking about programming technologies. So both have to
> be looking down the road when Java goes into COBOL-like
> legacy status. It takes a lot of investment in time to
> learn a programming language and their libraries well
> enough to write and lecture about them. So if Ruby "is
> the one" to make into the enterprise eventually and Python
> never makes the leap, then that's a huge amount of
> re-tooling that Eckel has to do. It looks like he's
> trying to protect his Python investment.

Actually, if you look at the last paragraph of the article, my hope was that someone would produce a useful feature-by-feature comparison of the two languages. Although I suppose you're right in a way; that would allow me to grasp Ruby in terms of Python, and would effectively "protect" my Python investment. I'm definitely trying to understand Ruby by putting in minimal effort and leveraging what I already know. My normal approach to learning a language, as you've observed, takes a huge amount of time and effort.

Cedric Beust

Posts: 140
Nickname: cbeust
Registered: Feb, 2004

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 9:37 PM
Reply to this message Reply
> Actually, there is a good point in here -- my guess is
> that someone on the Java team wasn't communicating with
> someone else when array was given the read-only
> length "field" and all the containers use
> size(). I would have liked Java's array to use
> size() as well (the compiler could have optimized
> away the call to produce the same efficiency as length).
> That would give me fewer things to have to know about,
> which is what I prefer when programming.

The length/size inconsistency has nothing to do with Java and everything to do with poor API design decisions made in 1995, probably by some very inexperienced programmer who had no idea that Java would become so successful.

There are a few more flaws in the Java libraries, such as Stack extending Vector, the misnamed System.arraycopy and Hashtable or the non-respect of get/set conventions in some core classes.

However, I have to say that overall, these collections have aged pretty well, even if I prefer the more humane classes that Ruby offers today.

--
Cedric

Alex Bunardzic

Posts: 546
Nickname: alexbunard
Registered: Oct, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 10:51 PM
Reply to this message Reply
> Actually, there is a good point in here -- my guess is
> that someone on the Java team wasn't communicating with
> someone else when array was given the read-only
> length "field" and all the containers use
> size(). I would have liked Java's array to use
> size() as well (the compiler could have optimized
> away the call to produce the same efficiency as length).
> That would give me fewer things to have to know about,
> which is what I prefer when programming.

It's amazing how the old school manages to always and unmistakably miss the point. Once again, I'm deeply impressed. The point is not that we should reduce everything to the absolute bare bones minimum. That would simply turn our minds into a machine.

The new school idea that I'm talking about is to force the machines to become more like human mind. Which is what Ruby is trying to do. Now, keep in mind that Ruby is just a first stab, barely scratching the surface, in its early infancy, suffering from all kinds of childhood diseases. Nevertheless, it is a first step in the right direction.

As I've already mentioned here, I like Ruby because it's the first computing concept I've stumbled upon that's allowing me to avoid being the machine's bitch. I used to be the machines bitch for the past 20 years. Believe me, that wasn't much fun. Tiptoeing around the stupid despotic compilers, trying to appease some quirky mechanical gods. It felt like hell (and still feels like hell each time I'm forced to go back and use the statically typed languages).

Now, using Ruby, I suddenly turn the machine into my bitch. I make the machine obey me!

Alex Bunardzic

Posts: 546
Nickname: alexbunard
Registered: Oct, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 10:57 PM
Reply to this message Reply
> The length/size inconsistency has nothing to do with Java
> and everything to do with poor API design decisions made
> in 1995, probably by some very inexperienced programmer
> who had no idea that Java would become so successful.

This is akin to saying that the Inquisition had nothing to do with the fanaticism of the Catholic church, and everything to do with poor decisions some clergy made at that time. In reality, however, the Inquisition was inspired by the broader climate of the Catholic church fanaticism.

In the same way, poor API design that Java is infested with was/is directly inspired by the bureaucratic nature of the language itself.

Kay Schluehr

Posts: 302
Nickname: schluehk
Registered: Jan, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 20, 2005 11:24 PM
Reply to this message Reply
> This is exactly why we cannot compare Ruby with Perl,
> Java, C#, C++ et al.

He didn't compare Ruby with Java, C# and C++ but with Perl and I'm really interested why it cannot be compared with it?

According to the legend of saint Matz it was Perl creator Larry Wall who was his personal hero and it is actually Larry Wall who never became tired to speak about the postmodernism of Perl, it's relationship to natural languages the many ways to express things etc.

Take a look here for acknowldegement and praise:

http://www.mcs.vuw.ac.nz/comp/Publications/CS-TR-02-9.abs.html

Marcelo Barbero

Posts: 5
Nickname: mbarbero
Registered: Dec, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 21, 2005 3:10 AM
Reply to this message Reply
> You talk like a machine when arguing the above point.
> Don't you realize that for all English speaking humans, it
> is obvious beyond a trace of a doubt that 'size' and
> 'length' of an array are equivalent? You should allow some
> meaning, some semantics to enter the picture when parsing
> a computing language statement. Allow yourself to go a bit
> beyond syntax.

Not being a "totally" English speaking human (that's to say, I'm not a native English speaker), if I see two functions: one called "size" and the other "length", I would suspect that there may be a difference that I can't see without reading the documentation. For instance, the first time I saw that two functions mentioned, I thought that "length" was like Python's "len", and "size" like C's "sizeof".

I think it's confusing.

James Watson

Posts: 2024
Nickname: watson
Registered: Sep, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 21, 2005 6:53 AM
Reply to this message Reply
> So the machine makes me its bitch, and all you can say is
> "I don't get it. What's the big problem."
>
> The problem is, I feel insulted, devalued and downright
> degraded if a $500.00 dirt-cheap little machine makes me
> its bitch. I don't like that. I simply can't stand it.
> Maybe you can, in which case my hat, nay my wig goes off
> to you.

If the machine is making you it's bitch, I feel sorry for you. I think you need to remember that this is a machine. If you were an auto-mechanic, would you get mad if you connected the gas tank to the water pump and the engine didn't 'know' what you really meant? I wonder if you really have the constitution for software development or any technical field. That you really care about this makes you more of a bitch, not less of one.

The other thing I'm struggling with here is all you are talking about is creating synonymous methods. It's not like you can't do that in Java or any language really. It's not like Ruby is reading your mind. There are Java classes with synonymous methods. Vector, for example.

Personally, I wholly prefer the one way to do it methodology. It makes other people's code a lot easier to read.

Lastly, if this is the greatest problem you have in developing software, you are probably doing something wrong. Good software development has a lot more thinking than typing. This should be a mild inconvienience only.

Joao Pedrosa

Posts: 114
Nickname: dewd
Registered: Dec, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 21, 2005 7:01 AM
Reply to this message Reply
"Good software development has a lot more thinking than typing. This should be a mild inconvienience only."

Exactly. It has nothing to do with performance of the programming language or with "one way to do it" -- those are superficial things that can be distracting at times.

mike bayer

Posts: 22
Nickname: zzzeek
Registered: Jan, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 21, 2005 7:28 AM
Reply to this message Reply
> As I've already mentioned here, I like Ruby because it's
> the first computing concept I've stumbled upon that's
> allowing me to avoid being the machine's bitch. I used to
> be the machines bitch for the past 20 years. Believe me,
> that wasn't much fun. Tiptoeing around the stupid despotic
> compilers, trying to appease some quirky mechanical gods.
> It felt like hell (and still feels like hell each time I'm
> forced to go back and use the statically typed
> languages).

hey alex, you talk a lot about not being the "machine's bitch" and all, but once your Ruby site needs to handle half a million transactions a day, ohhh youll be that computer's bitch again, just you wait.

Joao Pedrosa

Posts: 114
Nickname: dewd
Registered: Dec, 2005

Re: The departure of the hyper-enthusiasts Posted: Dec 21, 2005 7:43 AM
Reply to this message Reply
"hey alex, you talk a lot about not being the "machine's bitch" and all, but once your Ruby site needs to handle half a million transactions a day, ohhh youll be that computer's bitch again, just you wait."

Piece of cake.

Flat View: This topic has 262 replies on 18 pages [ « | 3  4  5  6  7  8  9  10  11 | » ]
Topic: The departure of the hyper-enthusiasts Previous Topic   Next Topic Topic: Java Applets + Ajax = ?

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use