Friday, January 2, 2009

Re: [BLUG] Looking to study further in computer science

On Wed, Dec 31, 2008 at 09:49:56AM -0500, Barry Schatz wrote:
> I don't think people should actually USE C. I just think programmers
> would vastly benefit from wrapping their minds around how the computer
> works at a low level before going out into the world. That said, there's
> a lot of critical software out there written in C that can't be replaced
> in any other language.

I really think more people should check out D.

It was written by a compiler designer. It fills the same void as C. It
is a systems programming language. Except, well, it is modern.

http://en.wikipedia.org/wiki/D_(programming_language)

--
Steven Black <blacks@indiana.edu> / KeyID: 8596FA8E
Fingerprint: 108C 089C EFA4 832C BF07 78C2 DE71 5433 8596 FA8E

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Looking to study further in computer science

It is hard to take compsci classes at IU and avoid Java.

However, if you are willing to learn Scheme, I've heard it is possible.

However in the commercial sector it is a lot easier to find paid jobs
programming Java than it is to find paid jobs programming Scheme.

But if the goal is to be a system administrator, I heartily recommend
dropping Java as soon as possible.

I fully admit that Java is a horrible language. It is horribly verbose,
and for no good reason.

Cheers,
Steven

On Wed, Dec 31, 2008 at 06:02:38AM -0800, August R. Wohlt wrote:
> If you're thinking about learning Java, I encourage you to read this first:
> http://steve-yegge.blogspot.com/2007/12/codes-worst-enemy.html
>
>
> On Tue, Dec 30, 2008 at 8:04 PM, David Ernst <david.ernst@davidernst.net>
> wrote:
>
> I have neither the time, the inclination, nor the depth of knowledge
> to get into a real flame-war about this, so I really hope that this
> doesn't degrade to that. But, Steven's message got under my skin a
> bit, so I feel I must say something....
>
> Really, I don't think there's a simple "Learn this language, it's what
> people use" answer. Here's my history in brief:
>
> Although I'm sure it's dating myself, I'll admit that in college I
> learned Pascal. At the time the "real programmers" stuck up their
> noses at Pascal and raved about C. I evenutally looked into C and now
> want to forget everything I saw. My favorite review of C is from
> Bertrand Meyer, roughly: "C is the closest thing we have to portable
> assembly language". You might be interested in doing things that
> require something like portable assembly (like, say, writing hardware
> drivers) you should absolutely learn C or C++. Otherwise, I say, stay
> away from it. The only other good thing I can say about it is that it
> makes fast programs, so applications where speed is of the
> essence... yeah. But... ick.
>
> Anyway, when the web was young everybody seemed to write their dynamic
> web stuff in perl, so I learned that, because I wanted to do that.
> Perl is definitely the language I'm most comfortable with at this
> point. I love it for what it is, but I have been leaning against it
> recently because of what it isn't, and that is a system that'll
> encourage you to build a well-organized large complex application.
> Perl was really invented to solve small problems quickly and easily,
> and when I have a problem of that sort, I'm usually half way through
> my perl script before I realize that I might have chosen a different
> language. But, the Object Oriented aspects of perl are weird -- I
> often say that they are somewhat cynical (read the official perl
> object-oriented tutorial http://perldoc.perl.org/perltoot.html to get
> a sense of what I mean). But basically, some people fell in love with
> Perl so badly that they thought they should use it for everything. I
> like to think that I kept my head a bit more than that, and when I
> found myself fighting against the language in some applications, I
> looked for other options.
>
> When Java hit the scene in the 1990s, I bought the hype... and,
> Steven, I must say, if you think Ruby is over-hyped, you're probably
> not remembering what it was like when Java first came out. Java was
> going to change our whole outlook on programming. It was going to be
> so simple that everyone was going to start programming in it, everyone
> would forget about all other languages, and, best of all, we would all
> "write once, run anywhere". I bought into this at the time and
> started researching Java. What I found is that is basically offered
> nothing to me. I do most of my work in the world of web development
> and system administration, and Java did not show me anything I was
> interested in. Over time, I've only become more cynical about Java,
> as nearly every java application I've had to use has been slow, ugly,
> and just generally depressing to use. I suspect that some people
> overcome the ugly-java tendency and I don't notice that they are java
> apps... and I guess that hardware has finally caught up with Java
> Virtual Machines, because I'm now less struck by everything Java
> seeming so slow. So, it's probably not as bad as I think of it being.
> But, suffice to say, I still have little interest in it. However, if
> I was looking to write desktop applications, I'm sure I'd look into it
> more. It's surely better than C.
>
> Then everyone started talking about Python. I suspect Python is a
> great language. I've barely used it. Basically, my feeling is that
> if I had a project well-suited for Python, I'd probably just do it in
> perl. Python's approach to object-orientation seems only slightly
> less an afterthough than perl's... you still have no real support for
> anything private/protected, and you still have that "explicit self"
> thing (c.f. http://beust.com/weblog/archives/000501.html) which is
> kinda funny in perl but more strange in Python which seems to be more
> proud of its OO support. And, I must admit, I'm hung up on the
> significant white space thing. I'm sure I could get over it,
> but... why?
>
> So, I turned to Ruby. Sadly, I must admit that I agree with several
> of Steven's criticisms of the language: code breaking on language
> updates does happen, much more often than it should... It is indeed
> slower than other comparable languages. Matz should have included
> utf8 support from the beginning. Having said that, it's nowhere NEAR
> as bad as Steven makes it out to be. Most strange of the things
> Steven said is: "recommends coding practices which are staunchly to be
> avoided in *any* other language." I don't really know what he's
> talking about there, but in my experience the BEST thing about Ruby is
> the coding practices that it encourages. Compared to Ruby, using PHP,
> Python, or Perl (or, really, C++) for OO programming seem very much
> like traditional procedural languages with OO tacked on. I can only
> imagine he's talking about things that other languages don't even have
> (so no wonder they should be avoided!). Classic Ruby-isms like:
>
> 7.times do
> whatever
> end
>
> should really make us all pause and wonder why so many languages
> consider it perfectly natural to write things like
>
> for (x = 1; x <= 7; x++) {
> whatever
> }
>
> At least many languages have now copied perl's "foreach $x (1..7)"
> approach, which is far more readable than the classic C-style syntax
> that java (foolishly, imho) emulated.
>
> But really, my main point about Ruby is this: Ruby has problems, but
> ESPECIALLY if you're thinking of learning a language for FUN, it
> should not be ruled out (much less avoided like the plague). Perhaps
> Steven Black and I do very different things for fun, but most of my
> fun projects do not rely heavily on long-term code-maintenance, native
> UTF-support, or fastest-possible execution times. Meanwhile, Ruby
> will make you rethink the ways that many programming languages do
> things, and even if you never use it for a serious project, you'll
> probably expand your understanding of OO programming in ways that you
> won't get from most of the other languages in common use.
>
> Having said all that, I'll again say that I can't really recommend
> Ruby over Python, and they are good for similar kinds of things.
>
> You see? You get me sucked into writing long emails! Now I'm behind
> on everything else I was going to do this evening...
>
> David
>
>
>
> On Tue, Dec 30, 2008 at 04:01:18PM -0500, Steven Black wrote:
> >If you want a job in the computer field, learning as much Java as
> >possible could be a big help. It is used extensively in the enterprise
> >sector.
> >
> >If you want a job at IU programming, Java is *the* language to aim for.
> >All IU's big projects are written in Java.
> >
> >Java is used heavily in the "enterprise" sector. In many cases these are
> >massive in-house applications. If I remember the job sector, around here
> >if you want to get programming jobs and not work in Windows, you pretty
> >much are stuck with programming in Java.
> >
> >Java has a large enough suite of libraries that learning more about it
> >will benefit you in the long run rather than adding another language
> >to your belt.
> >
> >If you were aiming toward systems administration, then there are a
> >number of languages I could point you at. However for programming...
> >Unless you're going to be programming in Windows and/or writing hardware
> >drivers you may as well suck it up and learn the most Java possible.
> >
> >A lot of open source software is written in Java. And even more software
> >plays nicely with Java. For instance, MySQL's Java interface is as fast
> >as the C library interface. For most other languages it is slower, as it
> >needs to use the C interface for the work, but for Java it has a true
> >native interface.
> >
> >OpenOffice heavily uses Java. If you want to script OpenOffice you can
> >basically either use Java, or use some odd version of BASIC that comes
> >with it.
> >
> >Now, if you're planning to learn a language for fun, I would recommend
> >you check out Python. Python is easy to learn and use, there is a
> >wide set of generally well-documented libraries for it, and one of
> >my favorite things: They've not only standardized on the programming
> >language, they've standardized on the *documentation* language, so all
> >Python code should be documented in English.
> >
> >Also, if you're planning to learn a language for fun, I would recommend
> >you avoid Ruby like the plague. The "best practices in the industry"
> >for Ruby produces systems which are unmaintainable and unsupportable.
> >(Literally, you will be unable to perform a security update, let alone
> >a distribution upgrade without breaking things.) The language runs
> >significantly slower than any other language in the class. (Of the
> >popular set of languages, they are only faster than Prolog.) They've
> >failed to adopt UTF-8 or Unicode even though the language is as old
> >as the Unicode standard, and the language was invented in Japan. The
> >language is poorly implimented, and recommends coding practices which
> >are staunchly to be avoided in *any* other language. It is over-hyped
> >to the point where a lot of people mistakenly think it is good for
> >something. In truth, it is not. (Except, perhaps as a warning.)
> >
> >You would be better off learning brainf**k than Ruby.
> >http://en.wikipedia.org/wiki/Brainf**k (Wikipedia redirects that URL
> >properly to the accurate name of the language. I have seen it called
> >simply "BF".)
> >
> >Incase you've never heard of it. Here is "Hello World!" written in BF:
> >++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++
> >++++++++++.>.+++.------.--------.>+.>.
> >
> >But really, my recommendation is: If you want to make an occupation out
> >of programming, learn as much Java as possible. Ideally try to make some
> >nice Open Source Java program, so you can show potential employers your
> >mad skills.
> >
> >Cheers,
> >Steven Black
> >
> >On Tue, Dec 30, 2008 at 01:28:22PM -0500, Ben Shewmaker wrote:
> >> I just finished my first computer science class at IU (covering Scheme),
> and
> >> next semester the class I'm taking will be covering Unix, Emacs, and
> especially
> >> Java. I'm wanting to push myself to learn something more at the same
> time
> >> (eventually I would love to get involved with some sort of open source
> >> project). Would it be wise to try to learn more than one language at
> once in
> >> the first place, or would I be better served trying to learn more Java
> than the
> >> course covers? What types of projects are developed with Java? What
> other
> >> language would be useful to try to self learn?
> >>
> >> Thanks for the info and Happy New Year everybody!
> >
> >> _______________________________________________
> >> BLUG mailing list
> >> BLUG@linuxfan.com
> >> http://mailman.cs.indiana.edu/mailman/listinfo/blug
> >
> >
> >--
> >Steven Black <blacks@indiana.edu> / KeyID: 8596FA8E
> >Fingerprint: 108C 089C EFA4 832C BF07 78C2 DE71 5433 8596 FA8E
> >
> >_______________________________________________
> >BLUG mailing list
> >BLUG@linuxfan.com
> >http://mailman.cs.indiana.edu/mailman/listinfo/blug
> _______________________________________________
> BLUG mailing list
> BLUG@linuxfan.com
> http://mailman.cs.indiana.edu/mailman/listinfo/blug
>
>

> _______________________________________________
> BLUG mailing list
> BLUG@linuxfan.com
> http://mailman.cs.indiana.edu/mailman/listinfo/blug


--
Steven Black <blacks@indiana.edu> / KeyID: 8596FA8E
Fingerprint: 108C 089C EFA4 832C BF07 78C2 DE71 5433 8596 FA8E

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Looking to study further in computer science

On Tue, Dec 30, 2008 at 11:04:12PM -0500, David Ernst wrote:
> Although I'm sure it's dating myself, I'll admit that in college I
> learned Pascal. At the time the "real programmers" stuck up their
> noses at Pascal and raved about C. I evenutally looked into C and now
> want to forget everything I saw. My favorite review of C is from
> Bertrand Meyer, roughly: "C is the closest thing we have to portable
> assembly language". You might be interested in doing things that
> require something like portable assembly (like, say, writing hardware
> drivers) you should absolutely learn C or C++. Otherwise, I say, stay
> away from it. The only other good thing I can say about it is that it
> makes fast programs, so applications where speed is of the
> essence... yeah. But... ick.

I learned C, what, 20 years ago. I moved straight from Borland's Turbo
Basic to Borland's Turbo C. This was back before Borland's Turbo C++.
Pascal existed at the time, but I really wanted more power. It was just
C with training wheels, and I was moving from Basic -- I didn't want
another teaching language.

If you want to write hardware drivers, don't bother to learn C++.
There's a lot of overhead with C++ that is just a horrible idea to have
in a kernel.

Unless people want to write hardware drivers or do some mad embedded
development work, I totally agree there is no reason to learn C.

My father was writing assembly before the invention of C. He was very
glad to find a "portable assembly language". Really, this is an apt
description, as the language has specific features originally designed
to make it to compile.

> [...] But, the Object Oriented aspects of perl are weird -- I
> often say that they are somewhat cynical (read the official perl
> object-oriented tutorial http://perldoc.perl.org/perltoot.html to get
> a sense of what I mean). But basically, some people fell in love with
> Perl so badly that they thought they should use it for everything. I
> like to think that I kept my head a bit more than that, and when I
> found myself fighting against the language in some applications, I
> looked for other options.

Much of Perl seems strangly glued together. Looking at the
object-oriented features in Perl makes it look stapled crudely. It is
really just strange.

> When Java hit the scene in the 1990s, I bought the hype... and,
> Steven, I must say, if you think Ruby is over-hyped, you're probably
> not remembering what it was like when Java first came out.

Java was hyped as a write-once use-everywhere language. That totally
failed, and only when they actually stopped pushing it as the One
Universal Language and decided to use it in server environments, with
specific listed virtual machines did it even start to be useful.

I well remember the dawn of Java. It was horrible. However, for better
or worse, it has matured in to *the* language of enterprise. (Then
again, they're replacing what? COBOL? FORTRAN?)

> Java was
> going to change our whole outlook on programming. It was going to be
> so simple that everyone was going to start programming in it, everyone
> would forget about all other languages, and, best of all, we would all
> "write once, run anywhere". I bought into this at the time and
> started researching Java. What I found is that is basically offered
> nothing to me.

I've seen the Java Compatibility Kit. I well know how they write
documentation for an abstract language with no regard for how the
implimentation works, or how different implimentations function.

It is just a bad design. You need to have your developers know how
things *actually* work, not just how the abstract language was designed.

> I do most of my work in the world of web development
> and system administration, and Java did not show me anything I was
> interested in. Over time, I've only become more cynical about Java,
> as nearly every java application I've had to use has been slow, ugly,
> and just generally depressing to use. I suspect that some people
> overcome the ugly-java tendency and I don't notice that they are java
> apps... and I guess that hardware has finally caught up with Java
> Virtual Machines, because I'm now less struck by everything Java
> seeming so slow. So, it's probably not as bad as I think of it being.
> But, suffice to say, I still have little interest in it. However, if
> I was looking to write desktop applications, I'm sure I'd look into it
> more. It's surely better than C.

Personally, I absolutely *hate* Java. However... if you want to be
a paid developer (as opposed to a system administrator like you and I)
and you want to do the development work in Linux... it is really your
best bet.

> Then everyone started talking about Python. I suspect Python is a
> great language. I've barely used it. Basically, my feeling is that
> if I had a project well-suited for Python, I'd probably just do it in
> perl. Python's approach to object-orientation seems only slightly
> less an afterthough than perl's... you still have no real support for
> anything private/protected, and you still have that "explicit self"
> thing (c.f. http://beust.com/weblog/archives/000501.html) which is
> kinda funny in perl but more strange in Python which seems to be more
> proud of its OO support. And, I must admit, I'm hung up on the
> significant white space thing. I'm sure I could get over it,
> but... why?

Unlike Perl, Python was designed as a whole from the ground up. Even
Larry Wall says that Perl is an amalgam of the languages of the time.

You may not understand the reasons for explicit self, one of the common
Python mantras is "explicit is better than inplicit".

A well designed API doesn't need private/protected locks placed to
prevent other developers from doing "inappropriate" things. Also, when
it comes to large APIs, those locks can get in the way of creating
components that fully integrate with a third-party API in a new way.

The emphasis is on *testing* and not on compile-time static checks.

But, yeah, I admit that white-space thing is weird for a lot of people.

> So, I turned to Ruby. Sadly, I must admit that I agree with several
> of Steven's criticisms of the language: code breaking on language
> updates does happen, much more often than it should... It is indeed
> slower than other comparable languages. Matz should have included
> utf8 support from the beginning. Having said that, it's nowhere NEAR
> as bad as Steven makes it out to be. Most strange of the things
> Steven said is: "recommends coding practices which are staunchly to be
> avoided in *any* other language." I don't really know what he's
> talking about there, but in my experience the BEST thing about Ruby is
> the coding practices that it encourages. Compared to Ruby, using PHP,
> Python, or Perl (or, really, C++) for OO programming seem very much
> like traditional procedural languages with OO tacked on. I can only
> imagine he's talking about things that other languages don't even have
> (so no wonder they should be avoided!). Classic Ruby-isms like:

Yes, things Ruby has that other languages don't have and other languages
do not *need*.

Ruby turns my stomach to the point I try not to think about it. Much of
the problem is related to a user community with absolutely brain-dead
stupid administrative practices, and no one in the community knows
enough about administration to correct the issue.

I do like how Ruby is proud of the equilivant to C's longjmp() function.

Assembly has the function, but no scripting languages support the
feature, and for good reason.

I also like the fact that for almost every online rant about the many
problems with Ruby one of the fanboys will comment, "Clearly you are
new." It is by far, my favorite Rubyism.

Don't even get me started on GEMS... Just look up the discussions
between the Debian folks and the Ruby folks. The Debian folks have good
administrative practices.

Ruby also has some strange confusing names, and a history of
half-completed libraries.

And the standard getopt() function apparently functions by setting
*global* variables. This *clearly* doesn't work well if you want to
integrate one script within another. I've needed to do this in Python,
and it is absolutely painless as they don't have crazy policies about
using global variables for no good reason.

> should really make us all pause and wonder why so many languages
> consider it perfectly natural to write things like
>
> for (x = 1; x <= 7; x++) {
> whatever
> }

I actually never understood BASIC's FOR/NEXT construct until I saw it
compared to C. It just makes more sense.

However, C's (and many other) language for() construct is just another
way of performing a while loop. (This is why Python doesn't bother with
it.)

> At least many languages have now copied perl's "foreach $x (1..7)"
> approach, which is far more readable than the classic C-style syntax
> that java (foolishly, imho) emulated.

This actually originates from shell scripting languages. Perl pulled
it in from there and cleaned up the name.

In Python there is only a 'for' function that works on 'sequences'
and 'interators'. Any class can be a sequence and/or interator.

> But really, my main point about Ruby is this: Ruby has problems, but
> ESPECIALLY if you're thinking of learning a language for FUN, it
> should not be ruled out (much less avoided like the plague). Perhaps
> Steven Black and I do very different things for fun, but most of my
> fun projects do not rely heavily on long-term code-maintenance, native
> UTF-support, or fastest-possible execution times. Meanwhile, Ruby
> will make you rethink the ways that many programming languages do
> things, and even if you never use it for a serious project, you'll
> probably expand your understanding of OO programming in ways that you
> won't get from most of the other languages in common use.

So you're basically saying that you do things for fun you're happy to
throw away? That is a very different approach to what I do. I like to
write things genuinely useful to other people, and that requires some
language stability.

Even though Ruby is as old as Python, it is significnatly less stable,
significantly slower (and eventually you will start to notice), less
complete, and much more poorly documented.

> Having said all that, I'll again say that I can't really recommend
> Ruby over Python, and they are good for similar kinds of things.

They are comparable languages. However, you can do everything you can do
in Ruby better and faster in Python, and it will be easier to write and
debug as it is better documented.

You can't really compare Ruby to Prolog, as Prolog really is doing some
neat stuff under the hood. There's a reason Prolog is slower.

> You see? You get me sucked into writing long emails! Now I'm behind
> on everything else I was going to do this evening...

Sorry about that.

--
Steven Black <blacks@indiana.edu> / KeyID: 8596FA8E
Fingerprint: 108C 089C EFA4 832C BF07 78C2 DE71 5433 8596 FA8E

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug