Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: "wooks" <wookiz@xxxxxxxxxxx>
- Date: 10 Jan 2006 06:12:26 -0800
Gerry Quinn wrote:
> In article <1136821381.805991.260590@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
> wookiz@xxxxxxxxxxx says...
> > Gerry Quinn wrote:
>
> > >A list is a data structure, and different means can
> > > be used to define it.
> >
> > The floor is yours. Give us your definition.
>
> An ordered set of data objects.
>
but lots of lists are not ordered. why does your definition require
them to be ordered.
> > > Actually it is an example of recursion. A function (+1) is called
> > > repeatedly to modify y.
>
> > no it's not.
>
> A function (+1) taking y as a parameter is called repeatedly, leading
> to successive modifications of y. Sounds like recursion to me.
>
wheres your base case?
> > > Iteration usually looks like:
> > > for( int i = 0; i < maxVal; i++ ) {}
> > >
> > > ..or
> > >
> > > for ( iterator i = begin(); i != end(); i++ ) {}
> > >
> > Right now tell me the difference between i++ and i=i+1?
>
> None. You can use +1 in iterative contexts too.
>
> > BTW none of these techniques are available in XSLT. What then?
>
> I don't know as I've never used it. It seems like a very limited
> special purpose language - maybe they are not needed.
>
Interesting solution. Anything that a Java programmer can't understand
is defined out of existence or classed as limited.
Unfortunately it's not the reality.
Now I've made clear in an earlier post why I keep citing XSLT as an
example.
Go to www.jobserve.co.uk and type Java XSLT in your search. I got 4883
jobs.
> > > The above succintly indicate that all elements of a set are to be
> > > processed, and the sequence in which this will occur. The first
> > > includes a counter, which is often very useful.
>
> > But it isn't so succint when some of the elements of the sets are sets
> > themselves. And supposing this nesting could be n levels deep. What
> > then?
>
> There are well known iterative mechanisms for fixed small n. Or you
> can use recursion if that is more appropriate. I've nothing *against*
> recursion as a technique - it has many uses.
>
In other words your solution doesn't scale.
> > > > climb(steps)
> > > > if no more steps stop
> > > > go up the first step
> > > > climb (rest of steps).
> > >
> > > Once they have learned to walk and count, they do what is best in a
> > > given situation. But I would say that they normally do:
> > >
> > > go to bottom of stairs
> > > if ( at top ) stop
> > > climb next step
> > > repeat
> > >
> > > This corresponds best to my second example of iteration.
> > >
> > Whats the difference between your "repeat" and my clim(rest of steps).
>
> The former is iterative, the latter is recursive.
>
I beg to differ. Your example is recursive the thing you are repeating
is the climb steps routine.
> for ( iterator i = begin(); i != end(); i++ )
>
> > > go to bottom of stairs // i = begin()
> > > if ( at top ) stop // if i = end() exit
> > > climb next step // i++
> > > repeat // loop
>
> > > > climb( steps ) // function declaration
> > > > if no more steps stop // if at-top stop, else
> > > > go up the first step // go up a step
> > > > climb (rest of steps). // call this function recursively
>
> > > If functional languages were so great, people would use them. That is
> > > the 'popularity' argument, and it is quite a valid one.
>
>
> > It's got alot to do with the same reasons why there isn't a
> > Lisp/Scheme/Haskell/ML for Dummies/Idiots etc. They require a fair
> > degree of mathematical sophistication.
>
> So does special relativity, and there is one for that.
>
> > Nevertheless here is an opportunity to better inform yourself.
> >
> > http://portal.acm.org/citation.cfm?id=286387
>
> They want money.
>
I'll summarise 2 reasons... the ones that I think are more prevalent.
1. Functional languages do not have the extensive general purpose
libraries.
2. They require a degree of mathematical sophistication which your
average Joe doesn't have.
They are not toy languages and they are certainly more powerful and
more expressive than Java.
> > > > The main reasons why imperative programming languages are in more
> > > > widespread use have nothing to do with them being better suited for
> > > > "real work", or being "serious languages". It's because they are
> > > > accessible to the mathematically unsophisticated which is a
> > > > description that probably applies to the majority of people employed
> > > > as programmers today.
> > >
> > > In other words, they are suited to real work by real people. And
> > > frankly, if a language is easier to use for ordinary folks, it is
> > > probably easier to use for everyone.
> > >
> > Can you drop the "real" nonsense.
>
> You used it first.
>
na na na na na ... jeez.
> > There are alot of ordinary folk writing crappy buggy software that
> > keeps crashing.
> > The ordinary "real" arguments are fine if you are solving a genuinely
> > simple problem.
> > Ordinary "real" folk didn't create the language that enables you to
> > come here and say what you are saying today. Check out the role that
> > Guy Steele had in inventing Java. Steele was an MIT student and one of
> > the inventors of Scheme.
>
> I am not wild about Java, but I recognise its popularity. According to
> Wikipedia, Steele joined the Java team after the language had been
> designed. But what matter?
>
If you are determined to take nothing from what I said it's a matter
for you.
> > > > The whole point Spolsky is making is that teaching people in Java means
> > > > that the odds are they won't practice these techniques in the first
> > > > place.
> > >
> > > And it's the same half-baked point that has been made for millennia,
> > > when those who consider themselves as members of an intellectual elite
> > > get worried that their inferiors are achieving much the same things as
> > > they can, without having bothered with the elaborate membership
> > > initiations. "They must be stopped", they wail. "How can the sacred
> > > work be left in the hands of ignorami?".
> >
> > What has that got to do with whether Java programmers are well
> > practised in recursion.
>
> It has to do with the fact that there's no reason they can't learn
> about recursion through Java. In fact, if they don't, they are being
> incompetently taught.
>
I've just given you the reasons that they don't learn it and one of the
manifestations. You've chosen to ignore them and continue to repeat the
same mantra. Not interested in arguing for the sake of it - it's a
waste of time.
> > > > But the fact is your average Java programmer can't parse an abritarily
> > > > nested regular expression and can't grok XSLT because they ain't used
> > > > to thinking recursively. Why. Because they work in languages that lets
> > > > them work around having to.
> > >
> > > When they need to learn it, they will.
> >
> > What you really mean is that they'll continue with their buggy
> > iterative hacks.
> > How can you know when it is appropriate to apply a technique that you
> > haven't even learnt.
>
> Knowing that is one of the things you are supposed to learn in college.
>
> But to be honest, any teenage Basic hacker learns about recursion. I
> can't imagine that Java students don't, and if they don't it's the
> fault of their teachers and/or their own lack of interest in their
> subject, not the language.
>
Sigh.
> > > Hopefully employers will choose
> > > to hire staff capable of doing or learning to do what they need,
> > > whether that includes the above things or not.
> > >
> > Thats why Spolsky wants to hire people that can write Scheme/Lisp,
> > because he can be assured they have the necessary capabilities.
>
> Cool - if all employers come to feel the same I assume they will become
> as popular as Java.
>
Once upon a time the same thing was said of COBOL......
.
- Follow-Ups:
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Gerry Quinn
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Richard Harter
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Willem
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- References:
- Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Casey Hawthorne
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Gerry Quinn
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: wooks
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Gerry Quinn
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: wooks
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Gerry Quinn
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: wooks
- Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- From: Gerry Quinn
- Interesting article by Joel Spolsky: The Perils of JavaSchools
- Prev by Date: Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- Next by Date: Re: which PC for software development?
- Previous by thread: Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- Next by thread: Re: Interesting article by Joel Spolsky: The Perils of JavaSchools
- Index(es):
Relevant Pages
|