Isn't this all opinion based? Just depends on how your mind works and what you find easy to work with?

Kev

Yes, to a degree its religious though I think there are good arguments that can be reasonably made. (Such as, to humans used to natural language, whitespace is a delimiter not a token and thus it is hard to read in environments where it is treated as a token.)

BTW, Jeff's definition of religion:

"Relgion is an opinion or belief into which you invest emotion."

Got a question about Java and game programming? Just new to the Java Game Development Community? Try my FAQ. Its likely you'll learn something!

I really don't see it. Perl is basically C after it's had a few drinks. You can use it exactly like C, all if/else, do while, while, for, ++, etc contructs are there (except Perl lacks switch), in the exact same form. Add in regular expressions, a looser structure, and a lot of shortcuts and that's it. You can very easily ramp up to more advanced Perl, and until you're comfortable with it just use Perl as a looser C with some nice conveniences. Nobody is suggesting Perl in its monstrous entirety needs to be used in all scripts.

Quote

I am sure that I could "learn" perl and in time read it and understand it with relative ease.. but I would consider that a tremendous waste of time.

This Perl phobia (not just you, it's quite common) is like a child taking his cough medicine. It's not that bad!

Perl saved me immense time. So much so that Java or C or even Python would have literally been impossible, the number of things I had to implement in the time I had. There's a time and place for everything, and chances are CPAN's already done it for you

Quote

I believe that people with a mind for programming can understand most of C/C++, Java, BASIC, Pascal, Python, etc.. just by looking at code that has been written in it, without knowing ANY of those languages ahead of time.

The Haskell community declares this quicksort program to be learnable from just looking at it, "You should be able to understand the program without any previous knowledge of either Haskell or quicksort." (from the official "Intro to Haskell", http://www.haskell.org/aboutHaskell.html). I really disagree. That program's also nothing, Haskell gets much more bizarre. It makes Perl seem like reading a children's book. Yet Haskell is an excellent choice for certain situations. There's no such thing as a one size fits all language, they've all got their strengths. Including Perl. They've all got their weaknesses. Including Java.

There's no such thing as a one size fits all language, they've all got their strengths. Including Perl. They've all got their weaknesses. Including Java.

Sure, I'm of the opinion that Perl's weaknesses GREATLY outweigh it's strengths. I fully admit that there are a few things that CAN be expressed easily and neatly in Perl... though the reality is that every Perl program I've seen is a mess. Of course that made me stop looking at Perl so I haven't seen all that much.

So, after seeing how awful the code was that was produced by people that actually knew Perl it was clear that there was no point in learning it.. Why spend the effort so I know how to write ugly un-maintainable code?

I find your Haskel example easier to understand than Perl, but I fully admit it still sucks. People may say that it fits certain problems very well... so does Prolog and other languages that never get used in "real life".

How about a class that stores its bytecode in a byte[] array, and creates its own classloader to load & resolve the embedded class, and then delegates all its private internal workings to the embedded class by using reflection?

How about a class that stores its bytecode in a byte[] array, and creates its own classloader to load & resolve the embedded class, and then delegates all its private internal workings to the embedded class by using reflection?

Cas

I think using reflection probably has to be outlawed in the Java Obfuscation Competition for the same reasons the pre-processor is outlawed in the C contest.

It just makes it too easy

Got a question about Java and game programming? Just new to the Java Game Development Community? Try my FAQ. Its likely you'll learn something!

...because the stack traces for runtime errors collapse that multi-line if check into a single line before reporting the number. With a code numbering editor, you will be told that the runtime error is in the "if( something" line, even if it isn't.

I only noticed because I was getting:

Quote

NullPointerException

in the line

1

if( myVariable != null

LOL!

[although, obviously, this is a bug with the 1.5 beta (line numbering for stack traces *has* to take into account EXACT source layout - including all blank lines as significant etc).]

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org