Why is Java Considered Un-Cool?
jg21 writes "After the Slashdot discussion on Paul Graham's 'Great
Hackers' essay, it had to happen. Java developers have taken umbrage at
Graham's assertion that "Of all the great programmers I can think of, I know of
only one who would voluntarily program in Java. And of all the great programmers
I can think of who don't work for Sun, on Java, I know of zero." Now in JDJ Sachin Hejip pinpoints the Top
Reasons Why Java is Considered Un-Cool and to tries to debunk them. He levels some of the blame at the Java compiler for "too much
chaperoning" and speculates that Java fails the geek test precisely because
"it's such a language-for-the-masses." But isn't he missing the point? Enterprise-grade apps and "coolness" may be inapproriate bedfellows. Besides, does any language offer both?"
I'm not sure the article author has actually read the Paul Graham essay that he is responding to.
He almost entirely fails to discuss any of the attributes that Graham assigns to languages that 'Great Hackers' like to use.
In particular, Graham claims that terser languages are more powerful, because studies have shown that coders churn out a pretty constant number of lines per day, regardless of the programming language. Java is anything but terse.
I could go on, particularly since the Sun JVM isn't open source, and Graham makes a point of claiming that Great Hackers prefer to use open source tools. I think frantic defensive articles regarding Java aren't helping anyone. The managers that choose Java don't read Paul Graham articles, and I doubt Paul Graham much cares what a Java-oriented business journal has to say about his articles. Please note that I am just relating the opinions that Graham has put on his website. I do not necessarily share his views.
Here's a hint: Paul Graham's view of the development world is fairly myopic.
...I'd love to tell you, but I'm trying to fix my $CLASSPATH
people just concentrate on the best tool for the job instead of worrying about things like, "coolness".
These, "my programming language is better than the rest and here is a list why" arguments are BS. Every situation is different, every problem requires different tools/methodologies to solve. You wouldn't go into the carpentry business and claim your hammer is the best hammer for every single job would you? You would be laughed at and possibly hit in the head with said hammer. Same goes with programming languages.
Monstar L
Firstly, most applications written in java run awfully slow which sends a lot of people to other languages. Secondly, virtual machines running byte code creates an extra step in compiling/rolling out programs which can stray away a lot of beginners. In general, not a lot of production software is written in Java, and a lot of people get into programming because they want to emulate something that already exists and make it better. C/C++ are languages of choice of the industry so they tend to go into them.
:-P
Also, i remember someone saying, saying java is good because it works on more platforms is like saying anal sex is good because it works on both sexes
I'd use Java for whenever I have a project that's a little bit higher than simple but doesn't require high performance. To me, it's very useful in the right situations.
Java is a tool - just like every other programming language.
People do/don't use Java for many reasons - the choice of a programming language in a commercial environment depends on many different factors.
I work in Java - I can't say it excites me but it does the job.
How can Java be considered un-cool when you stack it side-by-side with such horrors as VB6? I'd much rather be forced to use a decent object-oriented language then a very poor .... I don't even know what to call the abomination that is VB6
This is news?
Java is the new COBOL. No, I mean that quite seriously. COBOL means "COmmon Business Oriented Language". Java is the language of choice for modern day corporate application development. In the corporate world - which probably accounts for more actual lines of code than anything else - applications fall into two categories, forms (inputting data into databases) and reports (getting data out of databases). The corporate world wants legions of cheap, interchangeable programmers to work on these applications. Kids are taught Java at college or learn it themselves. The language makes it very easy for one person to work on another person's code, and it makes it quite painless to document your work as you go. That's the reason "hackers" don't like Java - they've just transferred their traditional dislike of COBOL to it.
I had to take java as part of my degree and from what I saw, making any halfway decent GUI involved giving your soul to satan. Maybe it's better now, but the mere act of creating and making a usable button involved more steps than lazy programmers like me are willing to follow.
Some of the things in java are terribly verbose. especially when going to design GUIs.
Using the language you just "feel" as if there should be an easier way.
I'm no fan of microsofts products but I think C# is an excellent language to program in. It addresses alot of Java's shortcomings and it is a joy to program in.
I try to read it (I guess it is being hammered by /.) and the stupid webpage reloads itself.
> Java is anything but terse.
I had to use Java back in school and I won't touch it unless my superiors threaten the branding iron (again). Java loads too much overhead and it doesn't have the same responsiveness as C based apps, IMHO. I don't think Java is optimized enough, and it shows. All the cross-platform support comes at a price and that price is speed.
The dangers of knowledge trigger emotional distress in human beings.
Java is exactly the opposite of a language for the masses. Overcomplicated APIs, quirky virtual machines... doing serious development using java requires a huge amount of resources in hardware and education. It looks more like it was designed to provide job security for Sun.
The site must use a lot of Java code.
After a while, though, people started noticing that Java is slow as mole asses. And it's a huge memory hog. But worst, I think, was when it started to dawn on programmers who actually think that Write Once, Run Anywhere doesn't have anything to do with the language you write in. It has to do with thinking portably.
It's very easy to write a non-portable app in Java. You have to make sure you use architecture and OS independent functions and algorithms if you want to be portable. And if you are going to do that, why not just choose any language you want (that has a compiler for the target OS)? Like C, which is fast? Or a scripting language, which is easy?
And of course finally, Java is uncool because it is a buzzword that non-programmers use.
Does it bother anyone else that this page has 65 ads on it? It frickin' hurts to read, it's almost as bad as http://www.seizurerobots.com/!
Also it bugs me that this guy has to rant and rave about Java, but he can only come up with eight "uncool reasons" to debunk. C'mon man, the standard Top Ten list has TEN items.
Java is uncool because it just eats up my cpu. I run a java program (PcGen) and the thing is insane in its resource use. I am also constantly crashing it. The fact that it can port from one OS to another - big whoop if it does it SLOWLY!
But the API's are nice (I am the eLearning industry and we utilize SUN LMS)
I mod down so you can mod up. Your welcome.
Python is an enterprise-grade programming language because its code is so readable. Sure, you can write a perl program faster, but six months later you won't be able to read it.
-russ
Don't piss off The Angry Economist
It's got the simplicity of C++.
The freedom from corporate interference of Visual Basic.
The speed of an interpreted language.
And you wouldn't believe how efficiently it uses RAM and CPU power.
I don't see why everyone doesn't use Java!
Recent benchmarks have demonstrated that, once running, a well-coded Java program is about as fast as a well-coded C program.
However, the "once running" issue is a big problem. Java startup time is slow, simply by virtue of the time it takes to load everything off of disk. And, unless you're running a server -- which most people aren't -- the startup time is by far the most important performance criterion in determining subjective performance.
Give me back my <20kB executables, and I'll consider using Java.
Tarsnap: Online backups for the truly paranoid
When I was in school, I did some Java programming. It was great for teaching programming for many of the reasons it's considered "uncool." For real programming, though, I find that the compiled programs run unbelievably slow. For a time I thought that it was my fault - that I didn't know enough to make my programs run any faster. But I've noticed it with pretty much every Java program I've used, including ones written by Sun's Java developers.
It's too big of a drawback.
Please, do we have to hear this comment every time Java comes up? It was cool to say that in the 1990's, but it's a little out of fashion now.
"No matter where you go, there you are." -- Buckaroo Banzai
Is that like "Downers and organ meat destined for ALPO cans"?
Eat at Joe's.
Java is slow when you are starting something up and the Java vm isn't started. When the vm is started, Java is outright fast. Many people fail to realize this is what's going on, but it's simply the way it works. The first time it's going to be very slow, every time after (until the vm is killed) it will be comparable to a C/C++ application in speed. When you're developing enterprise applications, that first time slowness doesn't outweigh the benefits of using Java.
This isn't to say Java is perfect for everything, but it is for some things.
From my employer's point of view, it makes me more productive than (most) other languages would, since I spend less time worrying about crap like header files, pointers, memory leaks, and so on.
So everyone wins. "Cool" stopped being important when I turned 18.
Lack of unsigned integer types makes java really uncool!
As I write this I feel I somehow must have got this completely wrong...
See how easy it is to assert that something isn't cool?
When I read Graham's article, I was disappointed. It had that air of someone being passed by, by a lot of fun. Saying Java isn't cool is like saying Scheme or ML isn't cool. It's just a personal preference, and when you express it, you run the risk of sounding anal and/or ignorant. His older articles were better considered.
Here's my utterly ignorant statement of the day: No matter how many ultra-cool hackers I know tell me that Lisp and Scheme and ML are cool, I never have fun using them. They force my brain into such an unpleasant state of nerdliness that the only thing I can program in them is a mathematical proof or some sort of logical system.. in short, I'm forced to become a boring CS professor using them.
Don't bother debunking reasons why Java isn't cool. The only path to cool is the acceptance of luserdom. Only when you have nothing to lose will you dare to do something audacious.
Look at punks. The only time they're cool is when most of society considers them fringe lunatics with no social graces. And then the rock happens again. It's when they're "cool" that the music invevitably begins to suck.
Being called uncool is a blessing in disguise. Thanks Paul.
This was the main concern among fellow students when I learned coding in Java some 6 years ago. But nowadays the execution speed matters rarely in a world of mutliple Ghz's. Maybe the shitty look of the Java GUI's like awt ( is this still in use?) and Swing might be a factor for uncoolness. Most people set cool == looks cool.
I personally like coding in Java since its syntax resemblences C++ and it's semantics is resemblences to smalltalk.
The only thing I miss in Java, and this is why I prefer C or C++, is that there are no pointers or any other means to play with memory directly butsince it's an interpreter there was no reason to implement it anyway, so i am pretty fine with it.
just my 0.02$
During the recruitment week in our university, one of the companies that visited was CA(Computer Associates). CA guys gave an options. The students can chose either one of C, C++ and Java for their exam. Well, 80% of the guys went for C, because it's their `first language'. Rest of them went for C++ and only 1 student out of 120+ students opted for Java. To cut a short story shorter, he got selected after a technical and HR interviews which were cakewalks compared to other guys' interviews. Well, if a language's gonna pay me 25,000 bucks(Indian Rupee) a month, I'd be more than happy to go for it. Cool or not.
Amen. The best thing (and imho only reason to use Java instead of C++) about a java app is that it can run on any platform. The wordt thing about a java ap p is that it can run on any platform.
The above makes the libraries and interfaces klunky and ugly. Also, it is not always a must that an application has to be able to run on many platforms. In this case it is far better to use tried & trusted C as it's quiker and gives you a better feeling coding in (My opinion).
Want to know why it's uncool to me? This may be flaimbait, but it's the truth. A disproportionate number of Indians favor this language and environment. This makes it nearly impossible for me to take these contracts since it tends to drive down rates. Same thing for oracle related work.
Disconnect your television. Do your own research. Draw your own conclusions. They're probably lying. Don't be a sheep.
>Java GUI is slower than native alternatives
Not really. Tried it recently? eclipse is a good example (eclipse.org) of fast java program.
>Java is not supported by all platforms
You can get a JVM for most if not all platforms. It also works on XP (don't confuse MS JVM as being a workable JVM, its years old).
>All the Java "binaries" I've tried relies on me having installed a local interpreter.
Actually you can get a program which will create an EXE for you, but then that defeats the purpose of Java doesn't it? Everyone moans about having to download the JVM, why don't people moan about the VBRUNxxx.dll and MSFC that you have to install to get EXE apps to run sometimes.
> Hey, I said this is MY list. I dislike object oriented languages,
Your basis of dislikes is hardly a good argument for what is wrong with Java.
I like Java. There, I've said it. It's easy and good for non-complex functions. When you start getting more complex, other tools have their uses. But for quick and dirty (or just simple) work, Java succeeds as an easy-to-implement solution. I think you can justify a tool that's a "language for the masses": Sometimes you just really need a good hammer.
Hello, my name is 744418 and I'm a Java user.
What it really comes down to goes soemthign like this: programming languages are just tools to be used as a means to an end, not the end in themselves. Java is great if I want to write a highly dynamic and modular system (dynamic state modelling), but I would shudder at the though of using it to perform high performance reading (such as for MD5 or SHA* hashing). It all hinges on what you need to do. Don't use a sledgehammer to do finished carpentry.
Infinity plus one!
..on the laptop I use for work (a Pentium-2 ...) it's just like that. Don't understand me wrong: I have programmed in JAVA, I liked it.
But as corporations nowadays still have little budget left for buying their employees decent PC's, JAVA still has this practical limitation.
Slashdot: stuff for news, nerds that matter, matter for news, stuff that nerd
There are Java pundits, and LAMP lovers. Not to mention .Net-sters.
.Net (MONO). For low-level use C++/C/Asm.
The real issue is use what works, regardless of 'cool' (hell, COBOL was probably cool once and is still used in some places).
As the story points out, Java is not used for low-level (device) programming. And Assembler is rarely used for data movement (ETL).
I say, for QuADs (Quick And Dirties), use a slower coding language that allows for quick development. For Enterprise-level Web/XML apps use something like Java or
Or try Bison...
i've read several of his articles, and none of them strike me as particlarly insightful. most are more of the "hey, i have this quirky idea, which i think is cool but is actually rather mediocre, and i have a lot of leisure time on my hands, so i'm going to flatter myself by dwelling on my quirky, mediocre idea in public" variety.
pr0n - keeping monitor glass spotless since 1981.
Java is slower because it's safer: automatic bounds checking on arrays, which helps to prevent buffer overflow attacks, etc. A program made in Java without an eye to security is going to be more secure than a program made in C without an eye to security. Also, for simple things, like programming web game applets, the speed difference doesn't matter much. I'm proud to say that my language of choice is Java.
Cyde Weys Musings - Scrutinizing the inscrutable
Apparently it's easier to use than the English language.
From the article:
How cool is to be the jock with the second fastest race-car in the block? and Top Reasons Why People Think Java Un-Cool - Debunked.
It never ceases to amaze me that people can learn the grammar of a programming language, but not the grammar of a spoken language. To be fair, English DOES have alot of "exceptions" to its rules, but come on. The above are basic grammar mistakes which any editor worth his salt should pick up.
"The best laid plans of mice and men gang oft agley..." - ROBERT BURNS
It's really time to dump your 386 and move on to at least a Pentium.
xer.xes -- 4181
Most developers I know basically slam it for it's reputation for being slow, and frankly, because it's not C, the geek Gold Standard. Perl has the same difficulty and has it's own cultish crowd (Perl users are the Greatful Dead fans of computer science). Python is somewhat trendy as well.
But Java....Java was designed to be easily learned, and to especially be used in web-based apps. To Unix geeks, that makes it kind of the Visual Basic for the Slashdot crowd. Not something to brag on.
Fact is, it's a great language, and it's still growing. A friend of mine is a professional Java developer (mostly server side stuff), and he's one of the brighter bulbs in the lamp. He loves it, and still thinks Java's potential is largely untapped. Whereas we know what C can and can't do, Java is still growing. He thinks it'll be used (and used effectively) for things we can't even imagine yet.
Life is hard, and the world is cruel
Perl.
No, seriously - properly written perl is both "enterprise grade" and as cool as hell.
Of all the languages I've ever worked in, nothing let me build systems as easily, as robustly, and as QUICKLY as perl did.
Remember the Daimler - Chrysler merger? Perl was the glue that unified the HR systems and LDAP directories. As far as I know, it still does. Our LDAP - LDAP replicator tool (written in Perl) was a damn sight more reliable than the native replicators, plus it would do schema translation, plus it had a smaller footprint.
Somehwere along the way, perl seems to have picked up a bad reputation for being illegible and obscure - and certainly one has the freedom to write the cliched "line noise" programs if one wishes. But perl done right can not only be legible, it can be beautiful.
DG
Want to learn about race cars? Read my Book
Swing programming in Java is Pane in the ass.
Emacs is good operating system, but it has one flaw: Its text editor could be better.
In my experience, being on the user-side of Java applications, it's not so much the quality of the language itself, but of the (apparently) poor programmers they must have developing these Java applicatiosn I have to use (typically internal-use-only tools within my place-of-business). Bad/non-intuitive user interfaces, illogical layouts, slow performance, and if I had a nickel for each time I got some sort of incompatibility problem based on what Java VM my browser is configured to use (or WHICH browser I'm using)!!!!
I cant speak but for myself, but we use some Java applications at my work. Some work just fine while others literally grinds the computer to total halt. IANAP (I am not a programmer) but somehow I get the feeling that some Java applications are just badly programmed. Why else the variation in performance?
Java lacks structs (I hate to get an extra .classfile for each inner class), gotos and enums. Those are cool features.
However C# is even less cool since you cant fall-through inside a switch (without the use of goto).
FFS people - how is this insightfull???
:)
Look at the arguments in the supplied link!
Mod this as the flamebait it is, and dont bite!
It's just not that hard to understand this. For good or ill, programming has always been an ego-driven profession. You hear stories of punch cards and marathon hacking sessions, and how cool it was that some guy arranged all of his code so that memory accesses were precisely in alignment with the rotation of the memory drum. You do not hear about how cool the fact that someone's applet can't crash because of automated bounds checking and lack of explicit pointers.
Java is seen as uncool precisely because it protects you from your own mistakes -- it's an attempt to make programming approachable to the masses, and the fact that it's forgiving makes it look like programming with training wheels. And just like the 50 year old MBA will never fit in with the Harley crowd, Java programming will never be seen as cool as "real" hackers' languages like C.
I think the guy needs to learn something about modern programming languages before sitting down to write...
For once I can say "Java sucks!" and be on-topic.
For all you moderators: "Neener! Neener!"
Bot Assisted Blogging
... where does that put C#? In the basement with the red Swingline?
The company I-Robot uses Java to interface a Linux box running Red Hat to all the sensors, cameras, and motors on their research line of robots. I spent four months trying to get the darn thing to work, CLASSPATHS and all to no avail. What a friggin nightmare. My master's thesis was going to be on that robot and now Auburn University is just building a robot from the ground up. Life's like that ...
From Sun's Java TM tutorial: "Purity Tip: Programs that use command-line arguments are not 100% Pure Java because some systems, like the Mac OS, don't normally have a command line or command-line arguments."
Command-line arguments are cool damnit! Any language that doesn't encourage them is uncool.
My other car is a slashdot UID.
Classloading is slow as all get-out, and even moreso when you're suffering through the startup of a Swing application, since Sun saw fit to make every Swing class reference every other Swing class.
Java is used a lot these days. There are three main reasons, in my view, why it became so popular:
So if you look at it purely as a language, it's just not that cool. You don't see amazing Java hacks. It's not great, it's just not bad. Add to that a few really irritating things (that are being addressed) like constant casting and having to check every exception all the time... Why would it be considered "cool"?
I believe posters are recognized by their sig. So I made one.
What mythical implementation is that? A common online chess applet can crash most of the JVMs I've tried it with. When I see "jsp" in a URL, I twitch uncontrollably. "Slow" and "flaky" are good words, but they don't nearly convey the necessary intensity.
I write software in decent high-level languages like Ruby and Perl all the time. It's not bug-free, but it never crashes the goddamn interpreter and if it's slow it's because I wrote it wrong.
Apparently, one of you two is smoking crack. Take a guess on which one.
"Obscenity is the crutch of the inarticulate motherfucker." - cloak42
Swing is a brilliant, although hard to learn, API.
Can someone please tell me the brilliant part about Swing. Honsestlly. I want to know! This is not a flameware. Please tell me what I am not seeing here. I code in java almost every day and i like it a lot but the Swing part i dont get.
"...The first time it's going to be very slow, every time after (until the vm is killed)..."
And things like the garbage collector kick in etc.
Java is an excelent platform. It just is not the be all end all platform.
BSD is designed. Linux is grown. C++ libs
To all you "Java is slow" parrots, I would just like to offer a counterexample. Where I work we serve up 70mbits a second, and the site is 100% Java/J2EE. The DBs are AS/400s and SQL Servers, but all the application code is in Java, and it performs quite well, thank you very much.
I think Java is super cool. Then again, I used to work in COBOL.
I don't see why it should be considered "uncool". It's nicely documented, easy to work with, resembles other decent programming languages and it's a scripting language. Yes, native apps are going to be faster, but we live in a 3+ghz era. The minor impact from script-compilation is negligable these days.
Hate me!
Java the language is actually fine. I don't know many people with major issues with it (at least, not compared to other mainstream programming languages - I'm not talking scripting languages here, so Python and Ruby zealots need not reply.) It's a little verbose, and it's imperfect, but it's an average language. It can certainly be improved, but I'd prefer it to C++ or even Objective C, if natively compiled and linked with a decent library.
Java the library, on the other hand, is a poorly organized and overly large confusing mess. It's hard to find the exact classes you need without having an intimate knowledge of the entire library, something hard to do because it's just so large.
Java the run time environment is slow, it uses memory poorly and programs generally take an age to load on all VMs, and vary in speed depending on the quality of the VM.
Java the portable environment is clumsy and eschews industry standards. Portable, standardized, solutions exist for many applications that Java deliberately ignores, from the POSIX APIs (Java doesn't even give you access to environment variables any more) to OpenGL (which Java deliberately ignores in favour of Sun's "higher" level wrappers.)
Java the system forces you to write portable applications, so Java is unusable for many small, one off, tasks. As a basic example, you can't write a one-off CGI in Java (the load time and lack of POSIX features makes that impossible), the "proper" way to use Java in this instance is to use a full blown application server like Tomcat. But if you're writing something small, that's simply overkill. Note: please don't respond saying "You're just using the wrong language", I know that, that's precisely the point, because of a few dumb design decisions, Java isn't suited to this, and those design decisions appear, for the most part, to be arbitrary and not in any way complementary to the system.
Java the web plug-in has, in the past, been unreliable and prone to crashing the container browser. While these issues have arguably been fixed in more recent environments, they've still left a sore taste in the mouth of anyone using them. Certain features, such as simple website authentication, generally become PITAs with Java applets because those applets rarely interface with the browser well enough, forcing the user to repeatedly re-enter usernames and passwords, or the developer to work around the issue with complex alternative authentication systems.
Java isn't cool or uncool. Java just has a bad reputation, a reputation justified by various design issues that all serve to reduce the number of applications for which you'd want to use it. It's fairly good at the "giant web services application" area, it seems to suck for the most part elsewhere.
You are not alone. This is not normal. None of this is normal.
The number of mis-informed posts on this subject is staggaring. An attempt to debunk some of them:
Java is slow - This is a myth. A long-running Java app running under HotSpot will over time grow to be faster than nearly any simmilar C or C++ app. Why? Because the Vm can over time learn how the codepath actually is executing and optimize it at the assembly level. The only way you could consistantly achive performance as good would be to hand-code the whole app in assembly, and thati s assuming you already know in advance exactly how the program will be used so you know what paths to optimize. This is highly unlikely.
Java UIs are slow - Java UIs are only as slow as your toolkit. Yes, Swing blows ass. But there are Java bindings for Gtk, Qt, and wxWindows, all of which are pretty cross-platform. And there is also the SWT toolkit from IBM which uses native widgets when possible, and when not falls back on its own widgets.
Java needs a VM so you can't run it everywhere - THis has to be the dumbest one of all. Since when can you write any resonably complex C or C++ application for multiple platforms without some effort? Any C/C++ app targetting anything more than basic POSIX will be littered with #ifdefs everywhere. With Java at least you can complile it just once, then ship multiple VMs , rather than having to adust your code and re-compile for every target platform.
I can't speak for anyone else, but the thing I don't like about Java is that the string handling sucks ass. There are how many different types of strings that you have to convert back and forth between in order to do something simple like accepting text from a network socket, altering it, and presenting it on the screen? At least three major type conversions that come to mind as the minimum-path.
Moderating "-1, Disagree" is simple censorship. Have the guts to post your opinion.
It's a joke - laugh :P
...Java's strong typing isn't a problem because it's strong typing. C++ does strong typing rather nicely. Haskell does it even better. Java's libraries, because they don't have anything like templates (at least until Java 5), require huge amounts of casting and instanceof checks to pull anything out of a container. That's when static typing gets in the way instead of being helpful.
I'm quite a fan of static typing, really (honestly), but not the way it works in Java. Of course, I hate lots of other things about Java too, but it's not because it's 'un-cool', it's because it's crap. Even if nobody used it, it still wouldn't be cool (I'd have a party though).
And although it pains me to say it of a Microsoft product, I hope C# takes over from Java, because although it's not perfect (no language is, or can be), it's for the most part what you might call 'Java done right'.
Miri it is whil Linux ilast...
Why do you think Java is slow? What was the version that was slow?
Summation 2
Maybe it's because a whole lot of us are too busy working on multi-million dollar financial projects to stop and tell you how cool it is? Java is all about the server side, so if we're not coding desktop apps, its because there's more appropriate software out there for that. That doesn't make Java uncool - there's a lot to be said about enterprise Java. Whether it's cool or not, it works.
By the way, I frequently use a very cool Java desktop app - It's an Amp/Effect editor from Line 6 that controls their Guitar and Bass Amps - It's all Java, looks and runs fantastic. Check it out if you have a Podxt.
Um...you've heard of Viaweb, have you?
Experience is a hard school, but fools will learn no other.
That's right, he used LISP.
-
Use a single data type for EVERY list (int, char*, struct DATA*, etc.)
-
Use templates to choose the list type for every list created
-
Pass a void* as data
Restricting programmers to choosing all variable types during coding is restrictive, and takes away some of the advantages of a heavily object-oriented language, like doing this (Maybe Java can do this, but I haven't learnt how yet)And still call the same function every time.Now I haven't been using Java long (started about 2 days ago) and haven't come across pointers yet. Are they in the language?
bring a system to it's knees just by invoking the interpretor.
Kosh: "Understanding is a 3 edged sword, your side, their side, the Truth."
First impressions for java weren't all that good. Back in the early days it wasn't just slow, it was painful. We'd ask "why does VB have a user interface that's so much quicker?" I still don't know. We also asked why every interface looked different. Java never did successful wrap the APIs provided by the OS and there's no reason not to.
By the time of the second impressions, Sun and Java zealots started to become annoying, promising silly things like it was faster than native code. Maybe in some cases it is, but certainly not where it counts: the GUI.
Oz
Compared to what?
Java is faster than perl, python, ruby, and PHP. If you want speed, use C or C++. Enjoy debugging the pointers and memory leaks (that is the "slow" part I care about more).
One reason Java is un-cool is that it is just another proprietary technology, owned by Sun. If Sun goes away, as it very well may, the Java code-base is at risk. And that would be very un-cool. Linux and Open Source development are cool. Geeks tend to like consensus-based technology that doesn't have a heavy intellectual property burden. Ultimately, Java is un-cool for the same reason that Windows is un-cool.
Marshall's Generalized Iceberg Theorem: Seven-eighths of everything is hidden.
...and then I'll tell you it can join the club of "cool" languages.
The problem with Java is that Sun really has managed it properly. We all thought it was cool when it came out, but the promises really weren't true. Write Once Run Anywhere mostly managed to work on different platforms, but the GUI is so god awful slow nobody really wants to bother. Its just easier to code native. I'm not exagerating here that even Visual Basic programmers could have come up with something better.
.Net products. Hate MS all you want but .Net actually is really easy to use.
Sun has let the technology stagnate while Microsoft has caught up (and IMHO surpassed) Java with their
Plus I don't know what's going on at Sun marketing, but they've descended Java into acronym hell. Plus the naming conventions don't really make sense now. The new version of Java is J2SE5 (I'm not even sure that it is this now).
I'm taking this from the perspective of desktop developers (rather than the server side as they seem to use Java fine). Java really does blow, and there are now better technologies to use. Sun has even ignored integrating other, better technologies (*cough* SWT) due to NIH syndrome.
If Sun went and fixed their mistakes rapidly (a bit late IMHO) then Java could still be cool. But everyone on the desktop who's used it considers it a steaming POS.
I wouldnt say that any of those reasons is why I dont like Java. My reason is the enforced OO that has a tendancy to drive me up the wall. The fact that everything must be an object and used properly. Is irritating if you are trying to do a smaller program that doesnt need the OO.
I know one reason I considered Java uncool was because people who claimed to know it were earning twice as much as me- a "lowly" sysadmin.
They never got calls after midnight, never once had to deal with "this needs to be done in the next 5 minutes", and it was the exception, not the rule, for them to do anything other than get told what to work on- and rarely more than one thing at a time.
Furthermore, while I actually had to demonstrate proven skills to be hired- they had to show up for the interview and have a pulse. Without naming names, let's say that 99% of them were on visas. They had atrocious English skills and/or horrible accents, so understanding them enough to support them was a pain. Rudimentary computer skills (for a programmer, there's little excuse) so they required lots of support. Lastly, they also tended to form their own clique and resisted multiple attempts by other staff to get friendly etc- pretty much ignoring the two or three programmers who were not from their country.
I once caught one of the new hires printing out a 600 page "learning Java" PDF well after closing hour- he didn't expect (foolish man) someone from IT to be around at 7pm. I hand-delivered it to his desk and told him that he had come within a millimeter of his boss finding out he was printing rudimentary books he shouldn't need. I was completely disgusted.
Wasn't as bad as the consultants who were paid $120 an hour for specialized development- and didn't know how to use Sun's desktop environment. Every time I walked into their room I found them playing solitaire, checking their stock portfolios- in one case, a guy was playing Quake (he was summarily fired within days).
Please help metamoderate.
That's not the real problem. Java is portable, and backwards compatible.
The real issue with portability is you need.. a virtual machine for
your platform. Sun ships it for windows,linux and solaris. I'm sure
even most C programs written for *nix are far more portable than that
Maybe because you need to post to /. to find out?
-- james
In my experience with Java, it simply falls behind on startup. It takes far too long to load the interpreter, load the byte code, and get going. What Java needs to compete is a true compiler. I need to be able to take a program, compile it for the OS that I choose, and make a lean and mean native executable.
The Java zealots panic. That would destroy the cross-platform ability of Java. Wrong. It would destroy the cross-platform ability of that one executable - simply meaning that I can give the slower byte code to all the other platforms that I don't want to compile an executable for.
Others will quickly point out that there are programs that compile Java to native executables. That is true, but I said I wanted a lean and mean native executable. Because of Sun's licensing, it is not legal to make a native executable that only contains the parts of the Java that are needed to get the program running. You must include EVERYTHING in the native executable - meaning it is required by law to bloated and slow.
So, after all of that, I realize what the problem is. Sun needs to fire a few lawyers so we can legally compile our slow and bloated byte code into lean and mean native executables.
The previous comment is purposely vague and generalized, but all of the facts are completely true.
yuck, the reasons given in the article are all just back-handed compliments. Like being asked by a job interviewer what's your biggest weakness, and saying that you work too hard and care too much!
How about something like - programmers want a language, not a lifestyle: and java's ambition to do *everything* is more than just about anyone wants.
How about the 'not invented here' syndrome? EJBs? Container-Managed Persistence? Ever try to get some other application to talk to a database where they used container-managed persistence? You're out of luck. And before you say go through the Java app - you need to understand running *major* analytics on a large database will do to java - like imaging marshalling 500 million objects...
At a java systems integrated during the dot-bomb I performed some productivity analysis, and discovered that it look us just as long to create a webpage using java in 2001 as it did to create a stateless page using cics on mainframes in 1989. Of course, this is partially due to the fact that we had one person creating the entire page in cics, but required separate html, jsp, & ejb people with java due to its specialization.
They hate it because to produce bug-free code in it requires far more time and money. The reason is pretty simple actually:
Lines of code, or more accurately, the size of the bz2 file of the source code stripped of comments.
A serious programmer tries to minimize the amount of junk in their program for the same reason a serious scientist tries to minimize the amount of junk in his theories: The more you junk you have hanging around the more difficult it is to analyze it and really get it right.
Java is just a bad language for that.
Seastead this.
I don't know about anyone else here, but I find that I have to think about what the machine is doing while I program. With Java it seems all neat and tidy and squared away and abstracted. I learned C++ first, and so I like to think about what's going on in the memory locations while I'm programming. With java, that seems to disspear. It's almost like programming with pseudo-code.
My blog
"And of all the great programmers I can think of who don't work for Sun, on Java, I know of zero"
Why do I get the feeling I wouldn't want to debug this guys code??
Every Java program I've run sucks up tons of memory and runs dog-slow. Now, I'm sure there are plenty of programs where people spend most of the time interacting with the user interface so raw performance doesn't matter and ease of programming is more important, but for general use, Java is a poor choice of language.
Java really isn't -that- slow. That's a common misconception.
Everyone thinks "Java is slow" because the only time they experience Java is in a Swing app. Swing is VERY bloated and therefore very slow. The only other "slow" processes in Java are Garbage Collection, which is pretty minimal if the app is written correctly, and the initial startup of the VM.
Look, for example, at Eclipse IDE. Eclipse is a Java app, and its extremely powerful and not very slow. Why? They use their own widgets that have less overhead, they are not using Swing widgets.
Also, a correctly written OpenGL java app has been proven to perform at 85% the speed of its C counterpart (yes C, not C++). A couple of guys (I can't find the link) ported QuakeII to java to get this statistic. Not bad considering the relative youth of OpenGL bindings in Java.
I once had a "Java Sucks" attitude myself (I've been a hardcore C++ programmer for over 9 years), but I must say, after using the language for quite some time (~2 years), I've become very fond of it, and have written several large & FAST Java apps -- in about 70% of the time it would have taken to write in C++.
First, I've read Graham's essay, and his definition of "Great Hacker" is on the vague side, and consists largely of platform advocacy. It turns out that his "great hackers" are all people he knows. Fair enough: He can't really judge anybody else. But that leaves him with such a small and selective set of data that his conclusions are meaningless. For example: He claims that all "great hackers" refuse to work on Windows. He works at companies developing software for UN*X. Not surprisingly, most of the programmers he knows are UN*X people, who don't work on Windows. So what? This proves nothing at all. He has merely suggested (however plausibly) that Windows developers tend not to develop for UN*X and vice versa, which is tautological. Dennis M. Ritchie has a Windows box on his desk these days, but Graham doesn't know Ritchie personally, so Ritchie's not considered. Graham's working from a thin set of anecdotes.
Secondly (and this has been said before), Graham's "great hackers" are prima donnas who refuse to deal with practical problems outside some very limited set of problems that they enjoy. I remember a story about Richard Feynman helping paint the walls at Thinking Machines when he worked there; I guess Feynman wasn't a "great hacker".
Finally, I often hear from Java advocates that the memory-lebensraum problem and the speed problem are due to programmers not understanding the internals well enough to work around their flaws. This is not said to be true of any other programming language on Earth, as far as I know.
It all sounds like a crock to me. Knowing the tools better will always help, but if only an expert can write usable code -- not great, but merely usable -- the language is junk, or at best the implementation is junk.
"Offtopic, Inflammatory, Inappropriate, Illegal, or Offensive" -- hey, that's me!
This is part of the problem of discussing Java.
Which Java?
Java the language? Jave the runtime? Jave the virtual machine? Jave the class libraries?
It seems like Sun haven't made this any easier for us to understand, in much the same way that Microsoft is rebranding everything as 'dotNet' a couple of years ago.
Java the language I like, although I think it's only become something I'd like to use in the most recent releases.
Java the runtime class libraries are very very very comprehensive, and usable in a verbose manner - but the write-once-run-anywhere? I'm less and less convinced of this as time goes on.
People seem to be able to install Flash without too much trouble. Just send the use to a java applet that does something kindergarten-ish like write "Congratulations, you've just installed Java!" and it becomes the same auto-download and install process as getting Flash done.
Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
Java is completely unrelated to JavaScript, JScript, and ECMAScript. JBoss is not a separate language; it's an application environment written in Java.
never built a real world system?
Posters recognized by their sig,
Unfortunately, your assumption is completely false. Paul Graham has been wildly successful in the corporate arena. For just one example, he's responsible for the software behind yahoo shopping's dynamic web stores (which was written in Lisp). While I don't agree with the man on a lot of things, his track record lends him quite a bit of credibility.
Actually, it's not that comparable. Method calling time is much much lower, which is where the stats claiming it's as fast/faster than C++ came from, but that's about it. For example, by the Fibonacci benchmark that was used. for which their results claimed similar times in C++ and Java - I managed to get an approx. 3000 time speed increase for the C++ version be making it non-recursive.
Having said that, for enterprise applications, better/faster hardware is frequently an option. For in-house applications, better hardware may even be drastically cheaper, compared to developer time. This is certainly the case for Java applications I work on - my time is expensive, and a $1500 server doesn't ever noticably slow down while running our application.
"...use C or C++. Enjoy debugging the pointers and memory leaks (that is the "slow" part I care about more)"
In the hands of a skilled C++, as well a C, developer these things are actually not the issue you made them out to be.
The better advantage here is the Java platforms ability to be dynamic at runtime without jumping through hoops as you need to with the more static nature of C or C++*.
* In relation to Java has a uniform platform to support this since it is its own platform. C and C++ have to implement them on their own based on the Arch/OS being used.
BSD is designed. Linux is grown. C++ libs
And hacking requires low-level access to the system which Java simply does not offer.
Yes you can add low-level functionality to Java, but you're not programming THAT in Java now are you.
I am a full-time Java developer and for all the goodness it brings there is also the lack of a decent referencing system to allow ingenious algorithms, good GUI mechanisms (Eclipse does a decent job to proof a Java GUI can work but is still no match for a native application) and, for instance, a standard and well-performing OpenGL API. There are many other things missing but most of it just boils down to the fact that it cannot access OS-specifics when needed.
Slashdot social media options: AIM, ICQ, Yahoo, Jabber and Mobile Text. Why no MySpace?
Java is not more secure than Ruby or Python. They all check the access to arrays, are object oriented, have exceptions support and a cool standard library. The only advantage for Java is that its standard library is bigger than the other languages.
How is this even considered an article? This looks more like a laundry list of complaints that some Java programmer (I use the term loosely) has heard over the years with some non sequiturs thrown in. He doesn't do any in-depth analysis of the few points that he does bring up, and doesn't mention any real criticisms of the Java language (e.g. much promised but little delivered garbage collection).
Let's look a few of the points he chose to include in his "analysis":
Java is popular. Anything popular isn't "cool".: What? First, prove that Java is popular. Second, how do you explain the iPod's coolness despite being wildly popular?
Java has a vast library that is available to all Java developers: (he means that you shouldn't re-invent the wheel, which makes it "less cool") Well, for most programmers comfortable with OO programming (including Linux kernel hackers; remember that the VM and VFS subsystems are OO design implemented in C), having a large toolset is a god-send, not something that's "uncool". In fact, most C++ programmers that I know think generic programming, which is pretty well enabled by the implementation of the STL, is pretty damned cool, in that it gives you a lot of high-performance power and reusable code for little-to-no work.
Java is an application programming platform (and therefore you can't do device drivers, etc.) Actually, who says that application programming isn't cool? Forms programming isn't very cool, but saying "applications programming" covers such a broad range of tasks that it's almost impossible to say it's any one thing with a straight face. I've done some incredibly cool applications programming in Objective C, and some really tedious applications programming in C. The language didn't change anything about the "excitement" of the task; it was all about the problem we were solving.
I don't like Java because I think it's a broken implementation of a decent idea. I prefer ObjC's object model and dynamism, C++'s operator overloading & template features and C's simplicity for the large majority of the programming tasks I perform, and Perl (a necessary evil) for anything that is small & quick enough that I need to do it on the command line. Java is a heavy duty programming language that's missing features like operator overloading and broken or brain-dead features like its garbage collection (how can you enforce memory reclaimation? Oh, you can't in Java. Hrm. Take a look at Cocoa's reference counting memory allocation/reclaimation system, or C++'s ctor/dtor paradigm for an example of how to do this correctly).
That's why it's not "cool", IMO: because it is inferior.
---------The early bird gets the worm, but the second mouse gets the cheese.
A program made in Java without an eye to security is going to be more secure than a program made in C without an eye to security.
I wouldn't count on that. The classes of vulnerabilities that affect typical C and Java programs are just different. Of course, buffer overflows aren't a problem for typical Java programs. On the other hand, lack of synchronization is not such a big problem in the C world.
For example, if you write a web application in C, it's quite unlikely that it exposes data from a different session if you hit the browser's back button. With Java, such problems do occur (because the same servlet object is used in different sessions and some programmers use it to store session-specific data).
This is absolutely true, there is no perfect platform/language/OS/tool/etc. for everything. Java makes developing large applications very easy and small applications more difficult. It makes creating portable code easy, it makes creating incredibly efficient code more difficult. When you're in a large network and need (for example) a web-based accounting system where you might have 30 different types of computers on multiple operating systems and hundreds of people working with the system at a time, Java is wonderful. When you're tasked with creating a (again, for example) inter-office messaging system where every computer needs a client, and some of these computers are desperatly in need of upgrades, you might look at Java but should probably use something else. If you need to make something quick to do a one-time task, you'd be insane to be thinking about using Java.
-1 ignorant
You have no idea do you?
Java - Yes, this is Java
ECMA Script - This has nothing to do with Java. It's a scripting language, it doesn't even have the same syntax.
Javascript - a name for ECMA Script
Jscript - Microsofts implementation of ECMA Script
Jboss - An application container...
I'm running FreeMind (a Java mind mapping tool) on Windows and Linux, with the same binaries. My colleague is running it on OSX, the same binaries... How is it not portable?
So can you make xcalc run on your HP calculator?
Idiot.
If a company brings their product in and it is written in Java, they are demoted and booted if any of their competitors have a remotely close app. I hope SUN sits up and takes notice of that last bit. People using your little system are losing money.
Your refering to SWT making JNI calls to the native GUI API calls. SWT framework also allows it to be portable.
However eclipse itself is built on java and isn't slow.
Only slowness I have seen in java is in applets in browsers or coded to the MS JVM.
First, an initial startup of a JVM does take up a larger memory footprint. But subsequent calls to the JVM do not... it's that initial runtime environment that needs resources. So if you're running several Java apps at a time (such as NetBeans, ConsultComm, Resin and other fun stuff memory and resource allocation is still much more conservative than apps that would exist outside of a runtime environment.
The original abstract windowing toolkit was kludgy, but the advent of the Swing API and the native look-and-feel within Java make things run and look like native apps. And with NetBeans GUI editor I can build windows and forms faster than a VB app in Visual Studio. Plus things are nicely skinnable by using GTK themes, QT themes or a combination of the two.
Plus let's not forget JDBC, something that I just can't live without anymore. Take a single file, drop it into your classpath, and you have instant access to whatever database you want. Want to change your database? No prob. Just drop in a different JAR file as your JDBC driver and tweak your SQL as needed. No connection recoding necessary. Much, much, much better than installing new ODBC drivers.
And system independence isn't to be taken for granted, either. I like being able to just create one package and have it run on my Linux box, then hand it to a WinXP user without recompilation. Keeps my apps easily cross-platform.
Of all the great programmers I can think of, I know of only one who would voluntarily program in Java.
That would be me!
I do have some level of admiration for someone who can code assembly in her sleep, but I'd rather focus on what the software does, and how it does it, than what it is written with.
In the wireless space, I've seen a lot of really excellent software--things that link position sensors and GPS and cameras and remote controls and other people. I've also seen a lot of crap. It didn't matter if it was written in J2ME or BREW or flavor-of-.NET or C++ ; what mattered was what the coder could do with the tools.
It's like any other field where talent matters. I'm sure Norm Abrams could build a set of Adirondack deck chairs using only a Dremel and a butter knife if he had to...
***Foucault is watching you..***
I love programming in Java. It is simple to program in, simple to understand, and I find it just feels 'clean' compared to say C++. The available API tends to be sufficient for most of my needs, and I find the documentation satisfactory and quick and easy to browse.
If I needed to write a quick, run a few times then throw away, command line application, I would code it in Java every time. For everything else I would unfortunately use something else.
On my aging 4 year old computer, graphical java applications feel slow and clunky to use. Even when the GUI has been coded correctly. Java apps with a poorly coded GUI are just unbearable. Also, the resources the Java VM uses isn't exactly small. Another thing is all graphical Java apps just feel out of place. They always look slightly wrong and feel slightly wrong. This tends to put the user off side from the start, and makes them feel that the application is somewhat substandard.
So basically, I feel that as it currently stands Java isn't suited to serious end user applications. As computer performance increases, and some of Java's future graphical enhancements are available, things may change.
However, while programmers are familiar, comfortable and satisfied with other languages, toolkits and tools, I see little incentive for them to start coding in Java.
---
Any man who can drive safely while kissing a pretty girl is simply not giving the kiss the attention it deserves. -- AE
Also their marketing department is high on crack. Java 1.2 = java2? Next up, Java5 ?! WTF!!!
And "Sun Java Server" is actually the next release of Solaris. 8-)
Anyone still concerned with whether or not their favoured language is cool or not is a 1) hack, 2) student, or 3) self-described 'geek' who's not nearly as good as he thinks he is.
Java works well in some environments and for some tasks, and poorly in others, and a lot of that depends on the programmer, not the platform.
Besides, success is its own argument. If you can't understand why Java is so big these days, maybe that's your fault, and not the world's.
Anyone who loves or hates any language, platform, or manufacturer, doesn't know what they're talking about.
Except that Flash 6 is like ~500kb and a decent JRE is like 30MB.
Flash 6 can install on accident even on a dial-up modem. You won't be accidentally downloading a huge runtime to get Java installed.
Crap, now when i go to the big computer programmer prom no one will dance with me. i like java because i can make applications on my computer that my boss ( who only uses a Mac ) can run on his. This is good. Also, its easy. cspring
That problem is solved if everything runs in Java, and Java is part of the kernel.
Heck, playing devil's advocate here, as I think JAVA as such has a very nice API.
I agree. Of the languages I am allowed to code in nowadays, it is also the most elegant one. One of the problems of Java is that there are gigabytes of example code on the internet of how not to program. Crappy memory and resource management and bad string manipulation are the worst problems. I rarely have performance problems, as long as I don't have to write a GUI or use an application server or XML related library.
Why the hell is this modded up? Java has nothing to do with javascript, jscript, ecmascript, or jboss. That faulty premise is so old and tired that it surprises me that people still are confused by it.
And as far as Java 1.2 vs. Java 2 goes -- ever heard of versions? You really think that everything in the original specifications were rock solid and that nothing needs to change? That's ignorant.
-1, Troll
Rule #1 -- Politics always trumps technology.
I have news for you, you WERE right, it is because of "programmers who weren't leveraging Java correctly". The same crap goes for bad C programmers. The problem is that the VAST majority of Java programmers who haven't worked in C rely ENTIRELY on automatic garbage collection and produce excruciatingly fat code. To summarize, in C:
... the big difference is the first one is also a leak.
many mallocs - zero frees == bloated crapware
while in Java:
many news - zero "= null"s == bloated crapware
Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
Why, are we just supposed to look the other way and ignore Java's enormous overhead now? You're not suggesting it's actually gone, are you?
Maybe Java is fast but what people see is that Java gui's are typically slower than hoped.
I've tried the 1.5 beta and it seems to go a long way toward addressing this problem. It feels as fast as native, and easily beats gcj in my own unprofessional benchmarks. But massive Java applications like Eclipse and NetBeans still perform horrendously slow for me, even with the server vm, and I doubt it can be blamed on any gui toolkit.
It's the startup time.
I have no complaint about the speed of a Java application once it is up and running. The only problem I have is that the runtime takes so long to heave its vast bulk into memory and fiddle with stuff before the app. gets control.
Notice that as the size of the app. grows, and the time you spend in it begins to dominate the time you spend getting there, this becomes less and less a problem. But it's still noticeable. The time-to-first-interaction is painful here on a box that opens non-Java, non-Gnome app.s in what my human nervous system perceives as zero time.
There's no reason writ in stone for code compiled to an abstract architecture, running on a suitable interpreter, to be slower than native code. It could be *faster*, if the architecture is well-designed and the interpreter well-written. I have no doubt that someone could trot out an app. which runs faster in Java than in native machine code made from well-crafted C.
Paul Graham's Great Hackers essay has really touched a lot of people's nerves. The wires are choked with people giving their point of view.
Yet again, though, I have had to stop and think - what is it about Java that makes people brand it as the most un-cool language on earth? I have had friends look at me like I was a poor sod for "having to" develop in Java. So, let me list all the reasons I can think why people consider Java un-cool.
Java has considerably fewer surprises and prefers not to add complexity to the language for rarely used features thereby resulting in a language where you cannot really make your friends go ga-ga at amazingly brief programming constructs. You need to write something substantial [like Gosling's Huckster] for them be to impressed with your programming abilities and not your language knowledge. This is probably the biggest reason Java is un-cool. It's too easy (although programming or software development remains as tough as ever). Java was always touted as the language that the "average" IT programmer can use. It's such a language-for-the-masses that yet again, it fails the "geek" test. And if you use Java, so do you.
Java has been considered slow for ages. The earlier allegations (1995) were true. However, with the recent advancements in the JVMs from Sun and IBM, Java runs pretty close to C/C++. Check this benchmark. Contrary to this, there are other benchmarks that prove that Java is slower. All considered, it would be fair to say that Java cannot be considered "slow" anymore, yet its stuck with the label.
How cool is to be the jock with the second fastest race-car in the block?
Swing disasters continue to give Java a bad name. Swing is a brilliant, although hard to learn, API. But the vast majority of Swing applications are so bad that they give Swing and therefore Java a bad name.
Java is a strongly typed language therefore you have to tell the compiler exactly what you intend to use. And if you make a mistake in the way you use it, the compiler has the guts to tell you that you were wrong. Too much chaperoning?
Java has a vast library that is available to all Java developers without any ambiguity. Thus, if you wrote yet another Map you would not be considered a data structures guru by Java programmers but a guy who hasn't heard of java.util.*.
Java did not have a good IDE that compared with MS Visual Studio. I think this one was true. I am not so sure it is any more with IntelliJ. The absence of good tools probably pushed away a lot of good programmers.
Java is popular. Anything that is popular has lost its elite status and therefore is not cool.
Java is an application programming platform. You cannot do cool things like device drivers and games, etc (until recently - but Java gaming is coming in a big way).
LISP?!? Someone please tell me that there's a full-featured IDE for LISP. I remember by bad-old days as an undergrad, stiching together CARs and CDRS in a rat's nest of parentheses, trying to figure out which left paren matched the right paren that was causing an error message...
I posted this in another thread before, but I suppose no on mark it up so no one noticed...........
The current list of cool Java Programs that I use quite often:
Eclipse IDE - www.eclipse.org
Azureus - http://sourceforge.net/projects/azureus/
IBM Community Tools - http://community.ngi.ibm.com/
and of course you need a GREAT JVM to run them:
www.ibm.com/java
Exec1: Bill, we have to do something about Java.
Bill Joy: What's wrong with it?
Exec1: No one's using it.
BJ: The hell they aren't. Java's everywhere.
Exec2: Well, maybe, but no one wants to use it.
BJ: Why?
Exec3: Maybe because the performance sucks compared to programs written in C++?
BJ: That can't be it. Sun hardware doesn't perform very well either, and people use our servers all the time! By the way, you're fired.
*uncomfortable silence*
BJ: Well, why else can it be unpopular?
Exec1: Sir, I think geeks won't want to use it because it's not cool enough for them.
BJ: Not cool enough for geeks? How the fuck does that even make sense? Someone get marketing on the phone and tell them we need an X-TREME mascot for Java, right away. That'll make it "cool" enough for these geeks.
Secretary: Yes, sir. Right away sir.
BJ: Alright, now then, what else is on the radar?
You see? You see? Your stupid minds! Stupid! Stupid!
Yes, pig latin.
Oh right...he was that Lisp dude...I forgot about that.
I only encountered Lisp in college for a while, and it NEVER seemed like a good "real world" tool. Its mix of data and code and love of recursion seemed excellent for certain cherry picked tasks...
Eh, I dunno. maybe I was just using too limited an environment. I have no idea what a "Visual Lisp" would be like.
SO YOU'RE GOING TO DIE: The Comic for Dealing with Death
Want to know the real reason it's uncool? It's because all those geeks use it. Us real programmers beat them up and take their lunch money...
Err, wait, that's just too weird too think about.
// file: mice.h
#include "frickin_lasers.h"
You're going to benchmark the value of a programming language by its ability to render a web site?
Doesn't that seem like judging the value of a television set by how well your DVD player shows videos on it?
You're defining the entire value of a programming language, by relation to other programming languages, by its ability to perform a distinct subset of tasks that could be performed with equal ease with a set of libraries for many other languages given that interest were great enough for such libraries to exist.
Oh, and java is quite portable. I develop a java app using j2ee via resin on my mac laptop, work on it at work using j2ee via jboss on a windows machine and depoy it to a unix box in the end. And if you wanna bother talk about swing applicaitons, anyone can write one. It takes someone smart to do it well. It takes an idiot to whine about it all day and find out that it's not hard to write one that works well. Not as fast as say, mvc, but works just like gtk "works".
java is a language, javascript is a language with a licensed trade mark which are different. I'm surprised you haven't learned this by now. Jscript and ecma script have nothign to do with anything. jboss is a j2ee server, just like apache is an httpd server and wsftpd is an ftp server.
Not always. Everything doesn't work "easily" off of c. Some use some form of assembler. Only reason you see more c support for simpler devices like calculators, is because c is easy to implement. a jvm isn't as easy.
-
ping -f 255.255.255.255 # if only
Also their marketing department is high on crack. Java 1.2 = java2? Next up, Java5 ?! WTF!!!
Best point you've made. Seriously, Sun's marketing depertment should be drawn and quartered. Java2, Java5, J2EE? J2SE? J2ME? Solaris versions vs. SunOS versions, putting the word 'java' on *everything*, etc.
"Ignorance more frequently begets confidence than does knowledge"
- Charles Darwin
The cool part is the VM, not the language. I've used Java, C#, C++, and many others. Java and C# offer modest improvements over C++ while taking away a number of useful tools. Hopefully at some point someone will get it right and come out with a language that is truly an improvement. Though I really would love more improvements in the development environments. Today's environments are 20 years old and not capable of managing the software we're creating today. Think about it, nothing much has changed since Borland's Turbo Pascal.
Bound checking and buffer overflow takes very little extra time on modern processors, typically less than 10%. So you have to find another reason.
I'd hardly say that Java is a training language for children. If I was training my child I'd go for a non-object oriented language to start. Besides that, to say a language is "for children" just becuase it is easy to use is kind of contradictory. I'd say that if a language was excessively hard to use THAT would be a flaw because you would end up with more bugs. Essentially, you're saying here that Java was too well designed and too safe for real programmers to use.
...no two people are not on fire.
The quote in my signature ("'Java is the Packard Bell of programming languages' - John Slattery") is an example of the adversity of change.
The man I attribute that quote to, was one of the developers of post-relational theory and worked on database design projects in the 1980s.
He is a big-time C/C++ guru, and very, very skilled at SQL (he writes all the queries for annual reports generation by hand, some of which as I have seen, can be over two pages long.)
He absolutely hates Java, because "it's too clean." He can't get access to memory locations, pointers, etc. This makes him feel powerless. He can't adjust to the fact that there are defined methods for doing things such as binary trees, linked lists, etc. whereas he used to roll his own every chance he got.
The language isn't the problem, the problem is that he's so set in his ways, he won't adapt to using a new language because of his preconcieved notions of it's capability and usefulness.
I think that is a bigger problem than the author of the article admits.
Every Java developer I've ever met has been on an ego trip, thinking they are the god of programming.
I want to know what it is that causes this mentality.
That is called typecasting no? I guess that Java has it. Even if a language is strong typed, it doesn't mean that you can't typecast.
:) ) language, and you can easily do what you wrote.
I consider Delphi as a strong typed (and *cool*
perception is reality
If this is too abstract for you, consider the following C code for a simple command-line interface:
struct command_t{
};struct command_t commands[]={ };
void run_command(char *comm){
}printf("Unknown command: %s\n",comm); }
Implementing help is left as an excercise for the reader. So is handling bogus input. The point is that this way I can add a command without touching the command parser -- just write the callback and insert it into the list. If there's some more sophisticate processing needed on some commands, I just add a flag to the structure and do the work once in the parser. Short of code generation, how would I do this in Java? A switch statement is not acceptable, because it means that everwhere I deal with commands, the data will be duplicated (embedded in the code).
That's just getting started, of course. Then there's the type system, which uses hideous wrapper classes around the most useful types (this can and should be done transparently without involving the user -- lisp, python and ruby do it fine). There's the complete lack of introspection. There's the absolute need to put every helper function into a class whether it logically belongs there or not, bloating classes beyond the problem-space items they represent. There's the misdesigned basic library so complex I need documentation every time I read from a pipe....
It just takes far too much work to make Java do anything I want.
Sig:Why copyright isn't a fundamental human right
Synchronization is not a problem for C because the average C programmer writes single-threaded code, and it tends not to be server-side (and if it is, it tends to be CGI, which doesn't scale well. It's possible to run Java in from a CGI script too). Of course it is possible to write multithreaded apps in C, but then synchronization becomes a big issue too.
Server-side scalability means pooling, caches, lots of things that imply resource sharing. This means some form of synchronisation, whatever the implementation language.
Erm, he did a start up in the 90's and literally crushed his competitors. The company was eventually sold to Yahoo! for approx $25 million. How much more in touch with the business environment can you get?
His trick was rapid development and the ability to debug and add features while he was still on the phone with customers. All of this using CLISP (byte-code compiler for lisp) in the mid-90's.
He generally rags on Java the most not because it's interpreted or slow or anything of that nature. It's because it's slow to write, has no REPL, and lacks good abstractions/is too verbose.
Thats a programmer error. A bad programmer can make anything happen.
Mine aren't. They run for weeks and months at a time. Startup time is irrelevant in the enterprise.
Blar.
Garbage collection. Some well-written Java applications allocate all the memory they will ever need at the start, and reuse these objects. Others rapidly create and discard temporary objects. Since garbage collection only occurs periodically, the system can end up with large blocks of unused memory.
I could never understand why Java couldn't allow the programmer to choose how often or when to perform garbage collection (end of function calls).
Vintage computer adverts: http://www.vintageadbrowser.com/computers-and-software-ads
Since when do "Hackers'" opinions of "cool" make a shit's worth of difference? Please.
I have learned and programmed in about 15 different programming languages (professionally in 5 of them), and designed a couple of special-purpose languages myself (also professionally).
My experience with Java is that it is tremendously difficult to learn. True, it is fairly easy to read and understand a Java program by someone else. It is also fairly easy to kludge something together. But if you try to program elegantly in Java, you are suddenly confronted with a huge number of standard classes which seem to have been designed by dozens of people who did not communicate with each other. Learning Java is like learning several different languages at once.
Java is the only language I know that makes a distinction between 'int' and 'Integer'. It is the only language I know that requires you to be fairly fluent in a completely different language (Perl) to use some of its default methods. It is the only language I know that has two different standard classes for the same functionality (Vector and LinkedList).
The idea behind Java was OK. The execution was terrible.
The only reason I can see why Java is not cool despite the fact that it is difficult to use, is the fact that it isn't elegant. Probably that was in the article, but slashdotting prevented me from reading it.
The main reason why I do not use java to build applications is because I cannot require users to install the java VM just to use my applications. In my opinion the only way Java will become a serious competitor is if it is implemented into the Operating system.
Pete Becker of Dinkumware has debunked a lot of FUD spread by Java Programmers. Pete worked on the Java Library & the C++ Library for Dinkumware (& earlier for Borland) so he knows quite a bit about the subject.
Here are his usenet posts on the subject.
Assembler? You pussy. I write in raw machine code, DIRECTLY TO MY HARD DRIVE, using a magnetized nail. Fuckin' know-it-all youngster.
'Standards' in computing only impress those who are impressed by things like 'standards'.
All other languages looked at are scripting languages with great interactivity. Just press/type 'run' after the bug is fixed and you get your instant gratification in milliseconds. Compiled languages like Java need e compile cycle. Java is the worst due to the long startup time of the JVM. I have never seen, even on multimillon-$ hardware, a snappy Java app. Even 'Hello World' has visible responsetime !
I prefer the Java language over perl, python, php, etc. The structure helps me to rapidly stitch a reliable program together. But I use the others more due to the snappy development cycle. I want milliseconds, not seconds !
Markus
I'm not sure I see anything wrong with that, though I guess really you have to examine "cheapest" very carefully. I'm sure that the Slashdot crowd is even less likely to program in Ada than in Java, and gripe even harder about the higher "overhead" in Ada than even Java has, and how it gets in the way of their coding.
Yet you have to look at the initial assumption of Ada as a programming language *for embedded systems.* For the Ada target market, they had studies indicating that 90% of the programming "cost" was spent in maintenance. From this perspective, initial coding is a nit. Even debug was rated as more expensive than initial coding.
So you have to look at the meaning of the word, "cheapest." (If they mean cheapest tools, regardless of suitability to the job, I have to agree with your attitude, though.)
The living have better things to do than to continue hating the dead.
Running on a 1gHz Pentium 4 256MB box here, and JRE startup still takes forever. It's really not much slower on the Pentium MMX 166 64MB box I have at home.
"Java did not have a good IDE that compared with MS Visual Studio. I think this one was true. I am not so sure it is any more with IntelliJ. The absence of good tools probably pushed away a lot of good programmers."
What about Eclipse? What about NetBeans? I have found NetBeans to be a very good IDE and I know that many people Love Eclipse. This is just wrong.
See my blog http://ilovecookes.blogspot.com/ for light hearted technical information.
The argument that it's portable fails to meet the fact that many of the times you do NOT want to care about installing the latest JRE on the destination computers. I'd be happier with compilation to native format. I know GJC and the likes, but they don't work 100%, although they're progressing a lot.
On clients, I find some resistence to Java due to the way it's marketed. "Isn't that for cellphones" - they ask. Stupid? Not really... that's the message the media hands out for Java nowadays (at least around here). We've had clients that knew where PHP, C and even Delphi fit in in their solutions, but failed to recognize Java. Maybe this is just something local to this country though.
At times, the verbosity of Java really gets on my nerves. I'm a lot more productive using a combination of VI and Screen than in most IDEs, so regardless of auto-completion, I resent having to type stuff like:
I mean, wouldn't it be possible to ommit the type again from the new operator? I'm sure the parser could infer the default type from the variable it's being assigned to.
Please, this is just an example. When you develop for a long time in something like Perl, PHP or Python you end up resenting writing too much. Sure those are typeless or just have yupe hints but still... I'm sure others will have different complains. What I sometimes feel is that compared to a pet language like D http://www.digitalmars.com/d/ it feels a tad old!
*ducks at the flames*
"I don't mind God, it's his fan club I can't stand!" E8
BecauseJavaIsSoDamnVerbose.QuestionMark()
It's fairly tightly defined, so you really can't experiment with it the way you can with C. I work with lock-free programming involving alternative forms of GC beside Boehm GC. It's not even something you can think of doing in Java. I keep mentioning JSR-166. That's not something somebody did in Java and then said "hey, let's put this into a native library". Those techniques came from outside Java.
Actually, programs are abstractions of electrical systems that, though I have programmed a simple CPU in an FPGA and wired up breadboards, etc. etc., I still don't understand. And Physicists don't even understand Physics! And thanks to Gödel, it's clear we don't understand Math! Argh. Who can save us?!
It's an indictment of Aristotle, Kant, the Enlightenment and the Scientific Method that all of our attempts at formalizing the universe blow up in our faces.
Until we approach every program as the algebraic systematic proof of a string-theoretic electrical circuit model, we will be burdened by the inexorable piles of poo that is the vast majority of the software written today.
Since when is an unsubstantiated flame with absolutely no substance considered "Insightful"? I guess it was moderated by overly sensitive Java developers.
By the way, don't take Paul Graham's comments out of context. His main argument wasn't about what language is better but about what tools are available that hackers like using. He also points out that with Java being touted as the language everything must be written in by PHBs because it's the trendy thing to do (rather than the right language to use) means everyone and their brother wants to learn to be a Java "developer" in order to get hired and make a decent salary. He points out that this makes it more likely to get someone not so good at coding if searching for Java programmers. By contrast, if you put in an ad for Java AND Python programmers (for example) you're more likely to get a good hacker in that position. Not necessarily due to Python being a better language but because someone knowing the language probably wanted to learn it for themselves, not because it was a trendy "I can make lots of money" sort of thing to do.
I equate it to the same problem we have with a mass of "point and click" admins (you know, folks that go through and get their MCSE's to admin Windows networks that don't actually know squat about networks, couldn't write a shell script to save their lives and generally don't know more than the basics and are unable to figure much out on their own apart from what they were trained to do). The problem here isn't that Unix/Linux/BSD is in itself better, but that you don't just have a bunch of geek-wannabes sitting down and thinking, "Damn, I need to learn FreeBSD or get Linux certified because it'll be easy and I can make loads of money and find a job easy!". Does this mean that all Windows admins are idiots? Of course not, it just means that if you advertise a position for a Windows admin and another for a Unix admin, your going to (percentage wise) get more capable folks
applying for the Unix admin position. You may get a few good folks for the Windows admin position but mixed in there will be a horde of point-and-click admins to go through and the problem is, those HR folks probably won't know the difference.
Geeks don't give a damn about coolness.
Have you ever seen a cool geek?
I rest my case.
I hadn't the slightest objection to his spending his time planning massacres for the bourgeoisie... (P.G. Wodehouse)
There are. Several big commercial Common Lisp packages (eg.), and for Scheme (a Lisp variant), a nice little free download from Rice University. I've been playing with the latter since reading Graham's latest, and it's sweet...auto-indenting, highlighting to show matching parens, source-level step-by-step debugging, unit-testing support....then there's Emacs support of lisp code editing (again with the parens matching), and the Bigloo package for well-optimized code that compiles to native or JVM (with full access to Java libraries)...google and you'll find plenty.
"Of all the great programmers I can think of, I know of only one who would voluntarily program in Java. And of all the great programmers I can think of who don't work for Sun, on Java, I know of zero."
Paul Graham sounds a lot like Bill gates in "Programmers at Work" as he talks about great programmers. Gates definition of a great programmer happened to coincide with his own skills and in Graham's case, great programmers hold the same views on Java that he does (and by inference Graham must be a great programmer too, right?)
In both cases, this is self-serving crap. We can debate the value of Java, but let's drop the question begging and the self promotion.
I know I'm going to regret posting this, because I know you folks like to take every opportunity you can to bash Microsoft, but I'll ask anyway...
.NET is getting some legs. Delphi has all but given up the ghost, and has pretty much decided that the only way it can survive is to be .NET compliant. My limited knowledge of .NET says that the reason .NET is gaining popularity is that it's easy to mix and match languages. So developers can do portions of this big mammoth project in C++, C#, J#, VisualBasic, or Delphi, and these parts can play together seamlessly.
.NET Framework being developed to work on Linux. If/when this becomes a reality, would that change your perspective on the validity of .NET?
I've been a Java developer for a number of years now, and generally like it, though I agree with a lot that has been said here. It's slow, and what I'd call "clunky".
The APIs are great, and for most things my code will run about the same on Linux, Windows, Solaris, or, in some cases, OSX. Given the project I'm on, this is a good thing. We are able to get cross-platform development done quicker and cheaper. Anything that we need good performance on (such as terrain databases and 3D display) we'll use C/C++ for. So there's this mixing of technologies that brings us the best of both worlds. Portability, ease of use, and speed.
Now it seems that
So, I'm wondering, is C# a good alternative to Java? It gives some of the safety nets of Java while coming closer to C/C++ in terms of speed. You all would know better, but I seem to remember hearing that there's a
Any thoughts are appreciated, but let's try to keep the Microsoft bashing to a minimum, shall we?
Java is not slow. Have you used it in the past 3 years? With the JIT compiler alone, you achieve C++ performance, in come cases better (believe me, I've had to run these benchmarks a million times), and with HotSpot, some java apps run so fast that similar speed can only be achieved by hand coding the app in assembly. HotSpot does on the fly optimizations at the lowest level. It pretty much learns what paths the program takes most often and optimizes for them, its a truly amazing and indispensable thing. The notion of java being slow came from the Swing gui. Swing is a little slow to react everynow and then, but its mainly due to its robustness. Regardless, even Swing isn't really an issue anymore. One of the greatest java apps I've seen recently that was coded really well and shows some of java's potential is Azureus. Java is a great tool in a toolbox of many great tools (i.e. python), and thats how it should be treated. Also, deploying an application with Java's WebStart makes deploying applications fun again:)
Regards,
Steve
I have to agree with you that one is more productive writing in Java than C++. However, saying Java is fast as long as you don't use Swing is like saying Phelps isn't much of an athlete except for the swimming. One of the main reasons for the existence of Java is platform-independent graphics.
Personally I have found Perl to be just as fast as Java, and easier to implement graphics applications. I can prototype in perl and code in C+OpenGL if I want speed. As for your statistic, a correctly written OpenGL app spends most of its time in the OpenGL library, which is all written in C.
Since /. is evidently causing a lot of sites trouble, why don't we add a wrapper that will automagically cache linked pages? That way, the site owners will be happy (lower bills) and /.ers will be happy (lower latency).
Please correct me if I got my facts wrong.
I'm proud to say that my language of choice is Java.
I agree. During my first two years of school we programmed almost exclusively in Java. We were the first incoming freshmen to take the introductory classes after they made the change from teaching in C++, and I noticed that a lot of the people who spent their time complaining about the use of Java were the same ones that failed the classes and changed from CS or IS majors to IT, Meteorology, or Living in the Basement majors. At the time, I was doing most of my schoolwork on an old eMachine with a Cyrix processor, and, although the POS pretty much screeched to a halt when I launched them, it handled Java apps fairly well once they got up and running. Uh, anyway, Yay Java!
-
CLASSPATH. This thing sucks. Worst design decision ever, I swear. Spend forever setting the frigging thing up, and hope to $DIETY things don't change. Oh, and make it so you need to reference individual .jar files too! What a great idea? What to add a library to your project? Be prepared to do battle with classpaths.
.jar's in a *direcotry* referenced by CLASSPATH? I'd love my CLASSPATH to just be "/usr/local/java/lib:${HOME}/java/lib" or something rather than specifying a million .jar files...
Anybody know why they decided to make it so you can't just put all
"Ignorance more frequently begets confidence than does knowledge"
- Charles Darwin
quite frankly i don't understand how this would be possible. Given generic compile of c/c++ code this would be true, but when the code is compiled for the arch it will run on, (and assuming the c code is as well done as the java code) i just cannot see it. So, anybody care to explain *how* this could be?
Of course there are full-featured IDE's for Lisp. In fact, the very first IDE's were made for Smalltalk and Lisp.
The fact that you can't understand Lisp speaks more to your intelligence than to the merits of Lisp. As Paul Graham says, he is talking about the tools preferred by the best and the brightest programmers, not by average programmers.
|>oug
>> Java GUI is slower than native alternatives
That may be true, however, it's still pritty snappy. on my Pentium 1.5 Ghz, I can still open 20 or so windows (JFRames), with a few fields/buttons/dropdowns in under a second. This is quick enough,
>> Java is not supported by all platforms, and is not supported by WinXP by default.
Java is supported by a good many more platforms (Windows/Macintosh/Linux/IBM iSeries/ Zseries/ to name a few) than Win32 apps, that are supported by , well Windows. It's not Java, or Suns fault that Microsoft have refused to install a JVM as default... Are you saying you do not like Java, because Microsoft does not like Java?
>> All the Java "binaries" I've tried relies on me having installed a local interpreter.
All the Win32 apps I've tried relies on me having installed a local copy of Windows, which Requires *86 compatable chip. At least Java allows you to decide which hardware you wish to run your app.
>> It's object oriented.
There's nothing stopping you writing a huge Java class, using nothing but public static methods (and end up with a procedural pile of shite)..
Here you go.
Who cares if a language is cool?
.Net convention. There Java was considered "uncool" because you had to think before writing a program. That did put some things in perspective...
My customers (and me) want an application that works, is maintanable and runs on platforms on which they haven't decided yet.
I use Java to program those applications. And they live up to their expectations.
I once attended a
He really doesn't get it. Java is not uncool for any of those reasons. Grahm states in his essay why Java is now uncool. Because it was overhyped. Because we are told it's cool. It doesn't have street cred. And a lot of people believed the hype when it came out, used it, saw it was too slow and got burned by the Hype. But in contrast, I see the same thing happening to Python. It's over hyped (although for the moment it has street cred), and it's slow. If I was a Java Dev'r, I wouldn't take the words of a man who still thinks Lisp is god's gift to programming language, that C++ is inferior to C, and that hacker cred is worth a pile of shit in a compost heap.
click me
Brainfuck is by far the best language ever concieved :)
Java is considered uncool among good programmers because good programmers seek abstractions, and factoring out commonalities. Java limits painfully the set of abstractions you can express.
The one most painful issue for me (when I wrote Java) was function objects. Java makes using functions as arguments, variables, etc. very painful (not to mention Lisp or Python's ideas of constructing functions on the fly). C# delegates cover a whole lot of that ground. I read the articles on java.sun.com explaining why there will never be delegates in Java; they are nothing but hubris and NIH syndrome.
Then you have the issues with collections (to be fixed, we're told, in 1.5) -- the omnipresent downcasts. Now, go read Stroustroup about downcasts. In C++, there are exactly two situations where you really need downcasts:
1) you're interfacing with non-C++ code, sending pointers back and forth
2) A design error
This is because C++ supports proper type abstractions.
Then look at Python, Perl, JavaScript, or any other dynamic language: downcasts are not needed and make no sense.
So -- the most common operation (modulu assignment and method call) in Java is one that is not needed in dynamic languages, and indicative of a design error in proper static-typed languages.
Java forces one to repeat oneself, because it excludes important classes of abstractions. This is why it sucks, and why it is uncool.
Applets (Java in your browser) make up a tiny minority of Java applications. I would be willing to bet less than 1%. Java is mostly used on the server where it is undoubtedly the best language for building applications (as long as you avoid EJBs).
Background:
Currently I program about 30% of the time in Java, 30% of the time in WebMacro (similar to PHP), 20% in C and the rest in Perl/bash.
1. "Java is uncool"
All languages have their purpose. Java is THE multipurpose development platform for Big Business (use google and do some research). So, yeah, it is uncool.
2. "Java is not write once run anywhere"
All of my software has been write once, run anywhere. Currently I develop and test on a Win32 machine and deploy on a Linux box.
In previous professions I have deployed software on Solaris and also deployed on IBM JVM's with code written and tested on Sun JVM's.
3. Why Java over c and the like:
I have outsourced work to India, and, irregardless of the standard of code returned, I have always been able to immediately takeover/finalize projects. The Java language makes things a lot easier to manage at a higher level. All of the magic associated to c/perl hacking is negated by javas rich libraries (definitely catching up to CPAN) and enforced syntax and of course javadoc. Maybe you guys are afraid of losing your superiority over the stupid managers etc?
In the past, when I have outsourced c code to India, I have spent many, MANY days fixing the mess or even rewriting things from scratch (I am fairly busy and I outsource prototype development - it is still cheaper than hiring a westerner).
4. Java runs slower:
This is the biggest crock of dog turd that anyone can use as an excuse against Java.
Of course it runs slower, IDIOTS!!! It has to run the jvm first and load up associated libraries. If this is too slow for you, then, look into native java compilers (jcc or whatever it is called).
The real slow startup time for java (takes less than a second on current machines) is not usually due to the jvm loading, but, due to poor programming of the target application.
5. Java is not open source.
So? Idiot.
To conclude:
* The geek community should stop being stupid about Java.
* Java systems will ALWAYS need C++/C/Perl/Bash interfaces, and there are many niche markets for people to work with integrating java software.
* What Java offers is what the big Corporates want, this is proven by the similarities of c#, and the latest Perl and PHP versions.
Stop blinding bagging Java and instead make money integrating with it!
Also, if you think that javascript and java are related, then, go back to your trailer park!
I think by "business enviroment" he means "prairie dog colony."
In that respect he's probably right, Paul would likely not fit in as a code monkey. Like he'd consider that a bad thing.
KFG
>>Java GUI is slower than native alternatives >Not really. Tried it recently? eclipse is a good example (eclipse.org) of fast java program. SWT == Native widget bindings. This is why you get to chose if you want to download the "Motif" or "GTK" version of Eclipse for Unix systems... That being said, GUI's in Java tend to be slow (IMHO) mainly because the developers writing them don't properly use the EventQueue and helper threads correctly. Writing a GUI which doesn't block in Java is somehow conceptually harder than in C/C++ even though the tools/methods are part of the SDK. Dunno why that is... >>Java is not supported by all platforms >You can get a JVM for most if not all platforms. It also works on XP (don't confuse MS JVM as being a workable JVM, its years old). This is sorta non-argument. Every platform has it's own JVM (just like every platform has its own C compiler). The problem is that JVM's are large, and often liscensed differently. (For example, HP has a funky license) With a compiled language like C, you have to track down compiliers for every platform you support, but you only have to ship the resulting binary. For Java, you have to ship the JVM which you have a lot less control over. Now, other interpreted languages, like Perl, have the same need to provide the "VM" but there are fewer providers. (Unlike Java which has a ton of different implementors all working towards the same "spec")
Thats a programmer error. A bad programmer can make anything happen.
Of course it is. It's a bit shortsighted to assume that Java magically makes bad programmers less risky.
Let me summarize the attitude:
Sounds like an ID:10-T error to me...
If you can't develop fast in Python, you're a fucking moron. Even my idiot ass has made usable programs in Python.
'Standards' in computing only impress those who are impressed by things like 'standards'.
Have you tried JRE 1.5?
There has been a massive speed-up in the load time...
HAHAHAHAHAHAHAHAHAHA.
Okay. Got that off my chest. But I should just point out that Python programmers can write the code as fast as anyone else. (It was kind of a main talking point for Paul Graham: great hackers like it because it communicates what they want to get done very quickly and with few lines.)
Lack of eloquence does not denote lack of intelligence, though they often coincide.
>Not really. Tried it recently? eclipse is a good example (eclipse.org) of fast java program.
SWT == Native widget bindings. This is why you get to chose if you want to download the "Motif" or "GTK" version of Eclipse for Unix systems... That being said, GUI's in Java tend to be slow (IMHO) mainly because the developers writing them don't properly use the EventQueue and helper threads correctly. Writing a GUI which doesn't block in Java is somehow conceptually harder than in C/C++ even though the tools/methods are part of the SDK. Dunno why that is...
>>Java is not supported by all platforms
>You can get a JVM for most if not all platforms. It also works on XP (don't confuse MS JVM as being a workable JVM, its years old).
This is sorta non-argument. Every platform has it's own JVM (just like every platform has its own C compiler). The problem is that JVM's are large, and often liscensed differently. (For example, HP has a funky license)
With a compiled language like C, you have to track down compiliers for every platform you support, but you only have to ship the resulting binary. For Java, you have to ship the JVM which you have a lot less control over. Now, other interpreted languages, like Perl, have the same need to provide the "VM" but there are fewer providers. (Unlike Java which has a ton of different implementors all working towards the same "spec")
Gee... I guess preview would have been good above... sorry...
Actually Java was not "designed" to be used in web-based apps. Its initial design goal was to be platform independent. AWT was thought to be the killer app of Java (ok, true applets are sort-of web-based).
It only became web-based after AWT failed due to horrible performance (early VM) requiring higher client-side system requirements. It moved to the server because at that time servers had the juice to power the VM and Sun needed something to keep it alive. In fact the "web-based design" are really just extension APIs. The servlet spec only made it to the standard distro in 1.4 (maybe a version earlier I forget this).
Not to knock Java, cause it pays my bills too. It is important if we insist on getting into these stupid bickering sessions to know what the original intention of the language was and how it evolved to what it is today.
think about that before you go to insult him again, and say that he's detached from the real world.
-toomuchPerl
> Java was designed to be easily learned, and to especially be used in web-based apps.
Exactly, and the web was designed specifically for graceful degradation. Most of the time, it isn't trivial to gracefully degrade a java applet. In many cases, Java is overkill.
Many business applications rely on form entry and report generation, which can perfectly (if not better) be done by server-generated HTML. As a bonus, the apps will also work using lynx in an SSH terminal. For a long time I have avoided writing Java apps for two reasons: First of all, I didn't need it because http+php+JavaScript already do all I want, and secondly, (perhaps nowadays misplaced feeling that) it is slow.
However, I recently started using Java in an area where I feel it does have its uses though: Desktop database applications. It gives users the feeling that they are working with a program instead of browsing the web, and the back button of the browser no longer gets in the way. I too, used to have the impression that Java was slow; however I also heard that nowadays its performance compares with C++, for which I found it hard to develop truely cross platform. In any case, in database/business applications, the bottleneck is hardly ever the user interface, but rather the database. I enjoy working with NetBeans, it's a very mature IDE. I haven't (yet) gotten to the point where Java breaks its write-once-run-anywhere promise, I guess it also depends on how you write your code. If you insist on calling the Windows API, your code won't run on a Mac or in Linux, but it's not fair to blame the language. Of course, my Java desktop database apps are still not going to present users with a windowed user interface on text terminals, unlike lynx.
Visit http://ringbreak.dnd.utwente.nl/~mrjb/growingbettersoftware to download your free copy of the book
look. If you have to make a call to free the memory, then you have no difference. It will still be a missed call. Besides, I do not think that it is GC that is the real problem. The real problem is that Java encourages lessor coders to do the work. These coders will take shortcuts and not think once about memory. They will use algo that involve creation of many times the # of objects needed and then will blame either Java or GC.
I do not believe for a second that a well written java app is going to perform nearly as well as a well-written C/C++ app. But, it will be more than adequate for the enterprise
I prefer the "u" in honour as it seems to be missing these days.
It's clear Graham got the cart before the horse in his Great Hackers essay.
He should have led that essay with this quote from "Succinctness is Power":
He should have reiterated that point again in the middle of the GH essay and he should have ended with it.
Seastead this.
Oh, look at Mr. fancy pants, he has a HARD DRIVE and a NAIL. When I was a kid we DREAMED of having a hard drive and nails hadn't been invented. We had a pointy stick and a deck of Univac 90 column punch cards.
Need Mercedes parts ?
To me, Java as a language is an excellent language. I think where it fails isn't the language itself so much as the user interface libraries. Most of them looks terrible and the ones that look decent are slow. At least this has been my experience. I have yet to use a Java user interface that made me "comfortable" as a user.
From a programming point of view, it's an excellent language. It has great features for producing code quickly as well as many features to minimize buggy code. But these things are only technically good. They don't necessarily produce programs that users want to use. To me this is the biggest failing of Java.
But like I said, it's not so much a failing of Java, but the UI libraries available for it.
Disclaimer: I've only done a smattering of Java here and there.
I can appreciate its potential and comprehensive libaries. I have even contemplated using it for personal projects for which I could choose anything. However, before I can even begin the first line of code, "It requires too much crap to be installed" is my sentiment exactly. By the time I set up the environment for Java (from scratch), I could have set up a db and begun a rudimentary, functional UI to start data I/O using other technologies (MS and/or OSS). More time can then be spent on biz logic and optimization -- even the UI!
Any yes, "Extreme object-orientedness..." does seem to involve buttloads of explicitly-called instances, each of which has several other similar classes that might do the job better but unless I have years of experience to know which is best, I just go with what seems to work.
The GUI, oh... *sigh* the GUI. Quite possibly the worst part of Java development. Improvements to this area are seen as just sucking less than the previous incarnation.
I know, I know... there are (good?) reasons and explanations to rebut all mine and the parent's comments but at the end of the day, I just need to get the job done; obstacles that can be avoided, at any level of development, will be given strong consideration.
During the last 20 years that I've been a professional programmer I've developed a theory that says, the more practical an application will be to the larger masses, the less cool it is to programmers. A corollary being that the tools to create uncool applications will also be uncool.
Consider the coolest programming jobs: game developer, theoretical research and embedded missile guidance systems, etc...
Now consider: accounting applications, banking applications and word processors - arguably the most used, most common, most practical of applications - and low down on the programming pole.
And then there are the tools used to build those applications: at the top of the pole assembly, C, Perl; at the bottom: Java, Basic, C#. Again the uncool languages are associated with building uncool apps.
It's a simple as that.
Finally, the exception that proves the rule is operating systems. Linux being a perfect example of a cool thing to work on and eminently practical. I would argue however, that the OS is unseen by the masses. The translucent background against which applications are run, thereby exempting them from the theory.
- Tune in next time for.. a clever sig.
Solid post but I wouldn't say bounds checking is the primary reason why Java is "considered" slow. I think the blame rests squarely on Swing, not AWT, Swing. I primarily write console and server side code in Java and it's plenty fast (Java's console line buffer I/O is NOT cool ... but that's a whole other story). Swing has gotten better as of 1.4 with the switch to Java 2D, but it's still not responsive enough for some. With the renewed emphasis on desktop apps, hopefully the gap between Swing + Java 2D and native widgets will close even more. That aside, getting bad Java programmers to stop writting bad code is a whole aspect ... maybe a "Programming 101" enabled optimizer? :D
Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
... for executing local applications. It consumes large chunks of processor time and memory (and the garbage collector never worked very fine), and is loaded and executed (so, add the loading time) for EVERY concurrent instance. Four or five simultaneous programs (think a simply web shop or corporative portal) can collapse your system, and its suposed to be designed for enterprise environments!The only thing Java does great is distribute the workload... Among the coders, I mean.
I'm a Java developer, and I completely agree with what you said. JBuilder is a waste, and Forte/NetBeans is absolutely atrocious: everything but the kitchen sink is thrown into the default install, and it makes it gargantuan and inelegant.
Having said that, however, you should be aware that 80% of Java developers these days use Eclipse. This is IBM's donation to the world of IDEs, and IBM has recently announced that all (!) future applications written by them will use the Eclipse framework. It is fast, uses SWT instead of Swing (meaning you have access to the native windowing subsystem, instead of having to deal with a new [Swing] one), and incredibly flexible. I come from a MS background, and I have to say that I *vastly* prefer Eclipse to VS.NET; it's leaner, meaner, and far and away more intuitive.
Did you try making the Java version non-recursive?
Experience is a hard school, but fools will learn no other.
I think that some of the attitude is not against Java so much as it is against the Java zealots. There are few things as off-putting as somebody else's religion, if it's thrust in your face. The whole OO scene has too many zealots and not enough skilful apologists.
.jar over to those folk who use MS Windows or MacOS.
I had an "ewww, Java" attitude and I got over it. It's a good tool and I'm glad I added it to my toolbox. I use it when it's appropriate, and select something else when it isn't. It's great, for example, when I want to develop on Linux, then just hand a
(If the truth be known, I'm actually quite vain about the number of different tools I use. I feel good about being able to use C, Java, Tcl, Perl, bash, and even (shudder) VBscript, sometimes two or three in one project. If I still had access to COBOL and DCL I'd be using those too, where appropriate.)
No, JSP and PHP are in the same category. PHP is great... if you like security holes and unmaintainable code.
However, the problem with Java is its damn slow,
That's an absolute load of shit. I wrote a content management system in Java and JSP (Simplicis) and it performs spectacularly.
its not nearly as cross platform compatible as it would have you believe,
Another line of nonsense. Two areas have minor cross-platform issues: complex file management and complex UI programming. Of all the applications I have written in Java (and I have been building Java apps since 1996), I have never encountered a cross-platform issue that took more than a few moments to address. And I have deployed my apps on systems as diverse as Mac OS X, Mac OS 9, Windows, AS/400, Linux, Solaris, AIX, and HP/UX.
its libs are a f***ing mess to say the least.
Some libraries are a mess; others are brilliant. That's about what I would expect from a language this mature. You end up with API's like JAAS that are a steaming pile of shit, API's like the date/calendaring API that are brilliant but too complex for common needs, and API's like JDBC that are dead on what an API should be.
For what it's worth, I'm a C++ guru with lots of experience in embedded systems. I would love to use Java on a regular basis.
It's part of my personal desire to get back into the applications arena. And it's because I like steady paychecks. And because I'd love to get more exposure to databases and Web services. (If you have tips on this, by all means share.)
I personally don't care very much if Java is a bit slower, more verbose, etc. Fact is, the language is cleaner than what I'm used to working with.
(To be fair, part of the prejudice results from debugging C++ code written by EEs and hardware geeks who have no clue about software construction. I would never have to work again if I had $1 for every time somebody created a data structure, saved it to NVRAM, and said, "Oooh, looky at my new database!" Uh huh. In your under-qualified dreams, my friend.)
In short, it would be nice to work with an OO language that doesn't have the more nefarious 1970s-era baggage of legacy C, and that (gasp!) supports threading and introspection cleanly. And one that employers are demanding...
--- The American Way of Life is not a birthright. Hell, it's not even sustainable.
He's always struck me as something of an ass.
When slashdot ran his piece bragging about how his Lisp software ran the most stores on the Internet at 14,000 - I sent him an email pointing out that Vstore ran over 500,000 on a Java system.
He said that "didn't count because it's different."
That's some serious ego.
JRE is about 7Mb.
I think the author could have done a much better job at debunking those myths. I, for one, am not convinced. Some snippets:
``you cannot really make your friends go ga-ga at amazingly brief programming constructs.''
Right. When you have to write BufferedReader in = new BufferedReader(new InputStreamReader(System.in)), that indeed doesn't give a strong sense of brevity. Nor does public static void main(String argv[]).
``Java has been considered slow for ages.''
And it's still slow. Each time a new release comes out, people get into the debate of Java is slow vs. you moron did you actually test that? Well, after 1.4 I have given up on testing. It's slower than unoptimized C for all programs I have tested with. Probably this is because I use the wrong kind of tests (ranging from simple loops and calculations to simple chat servers and clients), but just the fact that there are such wrong programs tells something, IMO. And startup time and memory usage continue to amaze me.
``Swing is a brilliant, although hard to learn, API.''
If it's hard to learn, what makes it brilliant? Certainly not its good performance or integration with the host environment. Themability and portability are good, but other toolkits have these, too.
``Java is a strongly typed language therefore you have to tell the compiler exactly what you intend to use.''
That's a fallacy. ML is also strongly typed, yet you don't have to tell the compiler the type you want to use.
``Java is popular. Anything that is popular has lost its elite status and therefore is not cool.''
You mean like Linux, Apache, Perl, PHP, gcc, etc. etc. etc. etc.?
Actually, now that I have read the full article, I don't think the author was trying to debunk any myths at all. More just summing up the points, so that those who want to defend/attack Java know where the battle is.
Please correct me if I got my facts wrong.
And if you really can't tolerate the parentheses, look at Haskell. It's about as easy to learn as Python and more productive (and there are JVM/NET bridges available too).
> not by average programmers
Gosling once noted that Java *was* a blue-collar language designed to get the job done, contrasting with the `purity' of Smalltalk. While I agree, there's a place for Java, I can only hope one day Sun/MS/IBM will see the light and offer a non-procedural language as a first-class offering.
Go somewhere random
Are you saying that VB is cool? I would consider this language as one of the most un-cool language ever.
perception is reality
It all sounds like a crock to me. Knowing the tools better will always help, but if only an expert can write usable code -- not great, but merely usable -- the language is junk, or at best the implementation is junk.
That seems a little harsh to me. Every language has its shortcomings.
For example, developers working in C++ who aren't experts will, on a project of any reasonable size, tend to write code that leaks memory like a sieve. In many environments, that's at least as crippling of a deficiency as Java's speed issues. I wouldn't say that's an indication that C++ is junk, however.
There's the old axiom in software development: Good, fast, cheap; pick two. It's pretty much the same thing in choosing or designing a programming language. Java's got its strengths over other languages, and it's got its deficiencies. Whether the strengths outweigh the deficiencies depends on the project.
In its day, mauve was all the rage: -kgj
-kgj
I think it's ironic you accuse the grandparent of being an "ID:10-T". I'd say that moniker is properly deserved of the person who thought users should be doing this.
You are not alone. This is not normal. None of this is normal.
There are lots of good reasons to use interpreted languages; they're easier to debug, they often have very powerful runtime environments, they're great for educational and research purposes. At the risk of short-circuiting the inevitable flamewar, certain languages are good for certain applications and there is no global measure of language "goodness."
Head down, go to sleep to the rhythm of the war drums...
But if you're writing for one of the BSDs [e.g. FreeBSD], what compiler [& libraries] do you use? Obviously you can't touch the GCC with a ten foot pole.
You use GCC. Just because you use a GPL compiler doesn't make your code GPL.
The reason Eclipse's GUI toolkit is fast is because it uses the native (non-java) GUI toolkit of the PLATform it's running on. Java has its place, and Eclipse has done a good job finding it, but they've also realized that there are some things for which it's not (yet) appropriate. Same thing with the OpenGL bindings.
"If English was good enough for Jesus, it's good enough for everyone else."
First, there's still anger and distrust of Sun. When Java first came out, Sun promised to help make Java a standard not solely controlled by any one vendor, and Sun started working with ECMA and ISO to make it so. IBM invested over $1billion with that understanding. Then Sun suddenly decided to take Java out of the standards process, and take complete control over Java. Yes, there's a "Java Community Process", but look at the process: if Sun doesn't like it, it's dead. Period. That's not an independence, it's a dictator model. And it's not necessarily benevolent; in an open source software project, you could fork the project if things went really badly (e.g., XFree86), but there's no mechanism for a true 'vote of no confidence' in the current process.
Fundamentally, developing in Java still primarily involves kneeling to Sun. We have lots of C and C++ compilers, with vendor-independent standards for them. Many other languages have standards, too. There's no need to return to a language totally controlled by any single vendor, that's a model from decades ago. Yes, there are other Java implementations, but not many; few others support the GUIs, and none support the massive library that's the primary point of using a language like Java. gcj does great stuff, but try compiling a normal Java program with Swing and other key libraries. C# is heavily controlled by Microsoft, and there are reasons to distrust that too, but at least Microsoft managed to release the language fundamentals to a more neutral party; why can't Sun exceed those low expectations?
And on most systems, implementing a Java system is a pain. It doesn't come with Microsoft, who's actively trying to kill it. It doesn't come with any purely open source software OS (Fedora, Debian, etc.), because it's not open source. This isn't a killing problem, but it does make development of Java applets essentially hopeless -- because it's quite likely that users will NOT have the necessary plug-in. You can do Java application development, and install the necessary libraries -- on servers that's not a big deal, but it's a little more painful on clients for client applications. But at that point Java enters a crowded field: there are LOTS of languages that can be used this way.
There's a lot to like about Java. But Sun has managed, through a series of missteps, to make a lot of people unhappy and avoid Java, even if Java would be a fine fit technically.
- David A. Wheeler (see my Secure Programming HOWTO)
One word: Eclipse
IBM took a different tack than Microsoft, yes. They wrote an app that didn't suck and made it open source to boot.
To reduce crime, make fewer things against the law.
In my experience (which isn't huge with Java, but I've used it for commercial work), one of the things I liked most about Java was that it actually tended to save me lines of code.
Oh, sure it's got an explicit full-on syntax, but I'm comfortable with that. What I was most impressed with was there was a vast amount of standard data types and APIs available to accomplish a very huge amount of stuff. Looking at C++ and the like, the APIs are anything but cross-platform. (Any helpful links to a good C++ API (not GUI toolkits) which is both POSIX and Windows might make me use that some more.)
For the type of code I was writing at the time (oddly enough, server side stuff behind a web front-end, no GUI) I found I could always find a standard routine to do what in the past I've had to implement from scratch.
I also specifically loved the good type checking and the like. I want that from my languages.
I'm actually planning on using it for some projects I want to work on for myself.
Would I say it's the perfect language? Nope. Would I claim it has all of the shiniest language features? Nope. Do I, as an old-school C-coder, think it's a straight-forward API rich language that I can get stuff done in? Damned straight!
Since I don't grok functional-programming and I despise languages with really wierd syntax and the like, for me, Java is like the Toyota Camry of languages. For the way I use it, it's fine.
Lost at C:>. Found at C.
This is why I really hate Java - Object casting and marshaling - Obnoxious try and catch structures for *EVERYTHING* - Int's can't evaluate to boolean - Native versus object typed numbers - Error, not warnings, on loss of precision - Lack of unsigned bytes - StackTrace mumbo jumbo - Compiler output is sometimes inacurate - CLASSPATH - Many others but these came top of my head
I have tried eclipse on several different occasions, and while it is an impressive IDE and feature rich, it is slow to me. Slow enough that it aways made me feel like i was being held back.
"Obscenity is the crutch of the inarticulate motherfucker." - cloak42
Java is slow - This is a myth.
I honestly don't understand why people are still repeating this. It _is_ slower than either native C++ or
Java bytecode is not easy to optimize, having been originally intended for interpretation (my, how silly that seems now!). This is usually a minor issue compared to memory. I also suspect that, using the standard Java libs, IO is bound to be slower than a more direct approach unless the JVM takes some shortcuts and makes some methods into special cases. But actually, from the point of view of my actual work it doesn't matter what the reason is -- performance critical serious number crunching is done in C++, and that's pretty much a universal, because everyone relevant has made the same simple observations I have. This C++ can then be wrapped with a Java interface for the benefit of other systems that depend on Java and for people who only care about whether the system is Java or not (and so that it works with WebSphere now that the company is locked into WebSphere, heh heh).
So, _whyyyyyyy_ am I _stilllll_ told by posters on
Whence? Hence. Whither? Thither.
Look. Some people who were obviously "smart" enought to do it, and "hacker-ish" enought to want to, have implemented Python and Scheme in Java. (see Jython, SISC, Jscheme).
Anyone can use all 3 languages at the same time, running in the same VM talking to each other.
Life is so easy when you Google for 2 seconds instead of bashing different groups of developers and trying to figure out why they can't all get along and write nice code they way they want.
-... ---
For a decent C/C++ programmer, memory leaks really aren't a big deal.
For a non-decent Java programmer, memory leaks ARE a big deal. They probably just don't know that.
Java's garbage collector helps with that, but if the programmer doesn't even know that it's possible to get memory leaks in Java, it's going to get them. I assume good Java programmers do, and know how to handle them. Same with C/C++ programmers.
If the programmer knows what they're doing in the language they're using, it's not an issue.
"Java is slower because it's safer: automatic bounds checking on arrays, which helps to prevent buffer overflow attacks, etc. A program made in Java without an eye to security is going to be more secure than a program made in C without an eye to security. "
The not so funny thing about this is that, as early as 20 years ago, this was true:
Lisp is slower because it's safer: automatic bounds checking on arrays, which helps to prevent buffer overflow attacks, etc. A program made in Lisp without an eye to security is going to be more secure than a program made in C without an eye to security.
One of the major differences is that Lisp allows easy early compilation to optimized native code, whereas Java relies on run time compilation.
Java may protect you from the common mistakes like buffer overflowas and whatnot, but that doesn't mean that Java code is automatically secure code.
As an example, a company I used to work for contracted out a single-signon module for our website. Basically the user would authenticate to us, and then be passed off to a third-party site. Well, the programmer who wrote the single-signon (in Java) never checked to make sure that someone calling his servlet had a valid session on our system, so by simply caching the page with the link, anyone could get a hold of a user's login to the third party site. Granted, the flaw would be pretty difficult to exploit, since the page was transmitted over SSL, but it was by no means impossible.
So it still requires a security-conscious programmer when writing security-related code, even in Java. The security consciousness is just at a higher level than in C/C++. Java will not force an idiot to write secure code.
Ah, but there is a way to force garbage collection:
System.gc();
Help find a cure for cancer. Join the [H]orde
Java is quickly becoming a de facto standard among management.
Some of the managers are technically savvy enough to realise that there is not much difference in choosing one language implementation over another. They choose Java because there are many programmers being taught Java at school. They are betting that should keep the labor pool large and the labor cost down in the long run.
These tech savvy managers know that python or curl is easier to write and maintain. They also know that other OO languages perform better, but they are adding the cost of staffing and outside support into their equations. They are projecting Java to become the next COBOL or C. None of them were 'perfect' coding languages, but they each dominated all other languages. What is technically 'best' is not always the 'winner' in the marketplace.It only needs to be good enough.
That said, most of the rest of the management (about the other 90%) likes the cool Java swag they got at the last convention. They think it makes them superior to wear it in first class while sipping cocktails and talking loudly on their cell phones about 'their' latest Java project implementation, and its overall downward effect on the cost ratios of delivering customer facing services, thus maximizing the returns for each level without jeopardizing the long term blah blah blah blah blah...
Indeed, I agree with you. All I'm trying to get at is this: There is *no* way that a interpreted or JIT compiled language can be *faster* than native code. It will always be second best. That being said, I agree with the advantages. I just don't understand why we have these huge flame wars... "Java is fast" "no it's not" "yes it is". Can't we just all agree that it's second-best in speed and better in debugging/hand holding? -kz
In the hands of a skilled C++, as well a C, developer these things are actually not the issue you made them out to be.
That's a tautology.
The real issue is that a developer has to spend some time developing this skill, and it is essentially waste for solving most problems. The same developer could have learned something else with his time that makes him more productive.
Just like the last article slashdot linked from this source. For one, it's a straw-man argument. He gets to set up the 10 greivances that he'll knock down. How about he ask Paul for a list of 10 greivances to knock down? Secondly, the greivances he picks and his arguments against them clearly show that he's incapable of thinking in the way that people who despise java think, which makes him a poor arbiter of such things. Would a great hacker really say "Java sucks because it doesn't have a cool IDE like MS Visual Studio?"
11*43+456^2
Wouldn't a Java interpeter in Java require another Java interpeter, culminating in an endless cycle of programmers who really want to be directors?
It's been a long time.
How can a language be un-cool? Could you call a hammer or a screwdriver "uncool"? And who'd listen to a guy wearing a beard, sandals, and white socks, getting red-in-the-face discussing the subtleties of static versus strongly-typed languages, deciding what's cool or uncool?
Programming languages exist to solve problems. Java happens to be among the best languages for mobile-phone apps (not the fastest, but very compatible), and scalable server-side apps. How can it be either cool or uncool? Personally, I wouldn't use Visual Basic to write production code, but I wouldn't call it uncool. It has its own niches.
This is coming from a former experienced (actually had a full time job for many years) C programmer that switched to Java programming (for many more years of full time employment) and would never go back to C (unless, of course, I had to to feed my family).
Similar to me. I've been programming in C for nearly 20 years and Java for nearly 10 (back when it was in beta). I've done huge projects in both languages.
What good is a program that can manage 1000 transactions a second when you only need to manage 10 a second. And besides, current archs require clustering of applications (for robustness) which also provides load balancing which in turn increases the throughput further. Java is more than fast enough.
It's that kind of thinking that creates the bloatware crap we have today. Stuff that performs worse than older software despite the fact that the hardware is 10 times faster.
This is EXACTLY what Java tries to be. The benefits of compiled languages (type checking, link checking) with the ease of use of a scripting language.
Hmm, some people would say "The disadvantages of compiled languages and not nearly as useful as a real scripting language".
Sun has been an inept manager of Java, but that shouldn't taint the language itself. If you don't like Sun's JVM, use IBM's. You have a choice
Nope. Didn't work; won't work. Java is dead because of what they did.
Who said "Extremism in the cause of object-orientedness is no vice"? Just kidding. Actually Java is not on the extreme end of "object-orientedness". More so the C++ (this is a good thing) but less so than Smalltalk. As a matter of fact, the C-ness of Java makes it quite easy to understand.
Any time I have to instantiate a "Point" class just to put in X/Y coordinates, that's going too far. Java is tedious like a low-level language but you don't get any of the power (no pointers, etc).
Java is better on the server but not just because of the available API's (no question those are nice too). A program that follows the Java naming conventions and good OO design philosophy is just easier to maintain.
The same could be said of any language. The disadvantages of Java take it out of the picture as a viable option.
Huh? Java was nothing if not new. Try explaining the benefits of garbage collections to a C programmer. He probably won't say "we were doing that with C in '83"
We were. And at least in C/C++ I have a choice. Plus I have more control. If you want complete ease of use, use a scripting language, if you want speed/power use a low level language. Java is the worst of both.
Java, as it is typically used on the client side, is about as cross-platform as Visual Basic.
The Web is like Usenet, but
the elephants are untrained.
Interesting points but I'm not sure what that has to do with your assertion.
At any rate, I think you're missing the main security concern: yes, VM languages like Java have some security features, but the security concerns should not be about the application but about the vm itself. I probaby cannot corrupt the virtual heap or stack of a java application since the code is managed, but I can corrupt the heap or stack of the VM itself, and in fact that's what the java exploits I've seen do.
All's true that is mistrusted
Another possible reason is because C/C++ has to free up memory as it goes; in Java, that cost is paid only during garbage collection (which might never happen during the lifetime of the process), and even when it does, in some cases it could be a lower total cost than the equivalent time spent cleaning up in C/C++. (Not taking into account libraries that add automatic memory management to C/C++.)
Look at some help wanted ads and see how many companies are hiring J2EE/EJB programmers compared to Python or perl programmers, and how much those positions pay. I don't care how "cool" a language is, I care that someone is going to pay me to use it. I'd develop in COBOL (shudder!) if that's where the jobs were.
Why is it that the proponents of "one nation under God" are so eager to get rid of "liberty and justice for all"?
Who would want to drink cold Java anyways? :)
Hyperom.com
Sometimes the safest thing to do is to idle a car w/ the lights out, or to visibly flash your lights at an oncoming vehicle, but folks with daytime running lights don't have that option. Sometimes you might want to speed up some code by ignoring typing, writing past the end of an array, or directly manipulating a pointer.
One has to admit that a statement such as
Of all the great programmers I can think of, I know of only one who would voluntarily program in Java. And of all the great programmers I can think of who don't work for Sun, on Java, I know of zero.
can only come from someone who doesn't really have a global picture and is a bit narrow minded. Otherwise, he'd think more, open his eyes and will find some happy Java developers around. Obviously, this argument is flawed on purpose and all he wanted to do is revive a closed debate that has been around since Java is out, which is a bit pointless IMHO.
I think Paul Graham should have been modded "flamebait" or "troll" at best.
I'm amazed that how all of the current "state of the art" Languages/Frameworks still haven't caught up to Smalltalk yet.
Smalltalk is a Language/Library/ and integrated development environment all in one.
It's had for over twenty years:
Java/C#/.Net wish they had all of this "20 year old" tech. They are good Languages/tools that are slowly evolving into Smalltalk. Why don't you just save time and go to the top of the food chain?
It's amazing how one research lab, Xerox Parc, could have been SO far ahead of its time. Its like software has stood still for twenty years.
You can explore it via the open source squeak project. Understand it is written for coders by coders so it takes a little work to come up to speed on it, but in my option, well worth the effort. And Morphic just rocks. http://minnow.cc.gatech.edu/squeak/1
I have no complaint about the speed of a Java application once it is up and running. The only problem I have is that the runtime takes so long to heave its vast bulk into memory and fiddle with stuff before the app. gets control.
You should try using Java apps compiled with gcj or one of the commercial traditional Java compilers. There's nothing set in stone that requires Java to be interpreted.
JRE 1.5 should help quite a bit also.
Galileo: "The Earth revolves around the Sun!"
Score: -1 100% Flamebait
You know what, at the end of the day, it's code. If you're a good programmer, it's readable, maintainable code. If you're not, no matter the language, it's going to be a mess.
Are you under some weird impression that if you use GCC your code must be licensed under the GPL?
Were the moderators under that same clearly mistaken impression?
What gives?
Finkployd
Martin Fowler of Refactoring does Java.
Erich Gamma of Design Patterns is a major player on the Eclipse project.
Besides why should people consider a language cool at all? Shouldn't it be, "What I can do with a language" is considered cool?
If someone is passing you on the right, you are an asshole for driving in the wrong lane.
About the only thing slower starting up than a Java app is a Java/Cocoa app. A Java device driver is initialised at boot time so you don't pay for the virtual machine creation every time you open it.
That's what I like about the language. A co-worker recently got transferred to a C++ project, and he spent a lot of time grumbling about the need to suddenly handle all of that after a stint in Java.
Laugh. I wasn't cool then either so what do I care? =)
Lost at C:>. Found at C.
We always thought it sucked for web developement also until we found echo and echopoint, now we build
everything with it.
Got Code?
Is it just me, or are there more sponsored links on that page than there is information.
I'm ok with people using ads to substidize content, but there are like 30 sponsored links surrounding the article.
It's simple, if you're a programmer, and you really are that good, you can do more with less memory and cpu cycles. I can write a program that runs on a $5 chip with 256 bytes of ram, and 16k flash, and have it controlling a robot. Go do that in java :)
I always prefer to start the year off with a bang - or, to be more precise, a series of loud hums, a crackle or two, and
I have notice a few Java clients for MUDs out there, but other then that I havn't seen anything else. Of, what java based MMO do you speak?
"Capital punishment makes the state into a murderer. Imprisonment makes the state into a gay dungeon-master"
This can, of course, be handled by the installation process but it is a pain in some ways.
IIRC this is also addressed in the release of Java formerly known as "1.5".
Galileo: "The Earth revolves around the Sun!"
Score: -1 100% Flamebait
I also like to do just what I need to do right where I need to do it. Why load a bunch of class libraries when you're only using a small portion of them? I can do the same thing without extra function calls then I save a bunch of cpu time and stack space. And don't even get me started on VM's...
"Can there be a Klein bottle that is an efficient and effective beer pitcher?"
Java is not more secure than Ruby or Python.
Java is faster than both ruby and python, so what is your point?
I'm reminded of an article written by C.A.R. Hoare once (you may remember him as the guy who invented Quicksort), where he quotes the late Christopher Strachey:
(the essay I refer to by the way is C.A.R. Hoare's "Programming as an Engineering Profession"). The grandparent poster shows exactly the kind of attitude Strachey so derides in the quote. If anything, this kind of fundamental disconnect seems to have gotten worse today than it was when Hoare wrote his essays on programming as an engineering profession and programming as applied mathematics.
Qu'on me donne six lignes écrites de la main du plus honnête homme, j'y trouverai de quoi le faire pendre.
You missed the entire point while happily going in the usual pitfall of blaming the garbage collector.
There ARE badly Java programs too, which can make things pretty slow, and various JVM implementations which exposes various GC behaviours.
Think twice, your brain has two hemispheres. Use them.
In the hands of a skilled C++, as well a C, developer these things are actually not the issue you made them out to be.
That's a tautology.
The real issue is that a developer has to spend some time developing this skill, and it is essentially waste for solving most problems. The same developer could have learned something else with his time that makes him more productive.
I'd count "paying attention to details" a valuable skill and one that increases productivity.
All you people complaining about Java GUIs need to check out SWT. It's the GUI framework used for Eclipse. It's pretty fast, cross-platform, easy to program for*, and takes advantage of native widgets so your apps look like native ones. I also recommend this book on it if you're new to SWT as I am.
*You still need to use layout managers as in the other frameworks, but this is a given for cross-platform apps.
Read my keyboard review.
> Straight C with makefiles is more portable now than java. We can program hp calcs with c right? Where's java?
Um, on about a few million mobile phones? And handhelds? And desktops? And toasters? Well, maybe on the toasters (yet).
Keep your friends close.
Keep your enemies in a little jar on your desk.
As far as needing to install the JVM before you can use it, I'll say that I was pleasantly surprised to find that Sun's packaging people grok the Microsoft Installer better than most third parties. I had little trouble pushing their JRE kit out to a couple hundred MS Windows workstations via an Application Management Group Policy. (I always have *some* trouble because I always want *something* weird, but Sun's people had already explained how to get the effect I wanted, and all I had to do was make a tiny transform to set it up.)
For individual installs, "go to www.java.com; click on Get It Now" is really not very hard, is it?
The java language is not verbose, in fact it is quite the oposite. I like Java over other languages because it has great documentation, a powerfull core library and small syntax. Swing sucks but I don't try to build GUI's so no problem.
I've worked with some really brilliant C++ hackers, who tested the crap out of their code, and they were still constantly finding the same old classic bugs. The fact remains that it is insanely difficult to write good C++ code. Java lowers the bar somewhat, so that you don't require superhuman ability to write decent software.
Why is it that the proponents of "one nation under God" are so eager to get rid of "liberty and justice for all"?
The only advantage for Java is that its standard library is bigger than the other languages.
And with Jython, Python programmers can program in Python and access all the
Java libraries. But that's becoming less of an issue as the Python library
offerings mature.
Whenever I work with Java, I always feel like I'm fighting it every step of
the way. Python, on the other hand, just lets me create working code without
ever getting in my way.
Python is what Java should have been.
*sigh* back to work...
Let's see, here I am at a command line, I want to run a Java application. Any other compiled language compiles to a native executable that you run by typing its name. Java is just this random archive full of "stuff", and you have to use a "run" command like we were back in 1968 before Bell Labs invented the executable bit.
.o in, and package require... no...? How do I do that, then?
Here I am running a Java application. I type the command line to start it, and wait. And wait. And wait. And wait.
Here I am with some code written in Java, and I want to call it from Tcl. Write a quick C wrapper, link the
Here I am with a library written in C, or Fortran, and I want to call it from Java... well, how badly do I want it?
Java is like Mac OS used to be, its own little world and the only way to play is to leave everything else you've ever worked on behind.
Well Java as I understand moves much of the optimization process down into the JVM whereas a compiled language like C++ does that optimization during compile time. Comparing the time I have spent waiting for C++ during the code, compile, run, code, compile run, I find I have wasted much more of my time. With the Caching of classes and dynamic inlining of code the JVM tunes up as you you go along.
... current and 1.5 (Tiger) coming in a few months are light years ahead of that old MS version and should be looked at seriously.
You are correct that this model has a start up delay which can be seen as a problem if you do a lot of startups, but like many applicatons say a web server that starts a JVM and keeps it running while the server is up it is a one time charge. I find that given the saftey of the language especially around automatic garbage collection compared with C++ my envirionment is rock stable and the online Web apps we have only come down with the hardware needs maintenance.
The folks compainign about MS Java have a good complaint as that was an old buggy version of Java that has not been in general use for years by people using Java from the Sun source. The new versions of Java 1.4
I write my code on NT and W2k platforms (java 1.4.2) and field the same code on WNT W2k Sun Solaris with out modification and no changes for envirionments. With C++ or C# and the java clone this is impossible at this time. I have in the past had to field C++ code on different platforms and that was not a very nice time.
How do you want to spend your time. Collecting your own Garbage, writting very very carefully so you can use your code in different environments, or do you want to just get the job done right and once and get on with it?
Drat, knew someone would ask that. No, never got around to it. Will try to remember to later tonight, and will post the results...
The trick to writing maintainable perl code is to optimise for legibility - and rigourously enforce it.
That means cutting back a little bit of some of the idiomatic perl shortcuts, especially the use or implied use of $!. It also means solid commenting.
I used to assume that every single perl program I wrote would be handed off to somebody else to maintain, and that this person would be relatively unfamilliar with perl - a skilled coder to be sure, but not necessarily a perl guru.
Accordingly, whenever I used some particularly elegant perl trick - but something that might not be immediately obvious - I commented the hell out of it, explained how the trick worked, and would even give references to the perl manuals where further reading could be had.
The end result - programs that not only did their function, but acted as perl tutorials for the poor bastards who had to maintain my code.
The side effect was that it made MY maintainence much easier too. If a bug was found in something I hadn't touched in years, optimising for legibility meant I could pick up where I left off without too much trouble.
I found that perl's expressibility made it EASIER to do this than "bondage and discipline" languages like Java. When there's more than one way to do it, you can choose the manner that accomplishes the task in the most human-understandable way, rather than being forced to think like the compiler.
I've noticed over the years that the best perl programmers (and in many cases, the best programmers period) are good writers, or have some sort of literary background. I think this is no accident; perl is a language for conversing with both the computer and with other coders.
That's it's strength, and its weakness. Like any expressive language, phrases write one can that difficult to parse are. But you can also write Shakespere.....
Perl is like English, where Java is like Esperanto.
DG
Want to learn about race cars? Read my Book
...is that if you don't program in Java, you've probably tried it. I know I've dabbled in everything from assembler, basic, visual basic, c, c++, java and various libraries/toolkits.
Java, by an order of magnitude, has the worst first impression of them all. Try writing "Hello world!" in a Swing window as your #1 tutorial. The start-up time, memory use and whatnot makes it seem like a dog.
Yes, I KNOW Java scales well to a large app, where it's not that relevant. That doesn't change the fact that if you dabbled in Java, and decided on something else as your language, your impression of it will be far less than stellar.
And you know how it is with every programmer telling you that "[MyLanguage] is the best", you'll think "Riiiiiiight. I tried it, not so buddy."
Kjella
Live today, because you never know what tomorrow brings
Some people weren't in class when the concept of an interpeter was explained, I think. ;)
It's been a long time.
But the reason it is uncool is because, outside of stuff written just for Java monkeys, there is no Free software to speak of written in it. Free software is written in C (65%), C++ (25%), and Python and Perl (all but the last 1%). Free Software coders have avoided Java for lots of reasons, including its not-really-portability, its bad performance, its hasty and stupid language and library design, its corporate 0wnedness, and their own resistance to hype and idiotic jargon.
Java killed Freenet in the crib.
"But my mom says Java is cool!"
That should read "especially the use or implied use of $_"
My bad.
DG
Want to learn about race cars? Read my Book
And you would've missed that question on the Java Cert exam. System.gc() is only a suggestion. You can never force garbage collection.
The Red Pill
And the "developer that creates scripts of executable that start the application" is essentially implementing a hack to get around this problem, not solving it. Java is supposed to be cross platform remember? You're supposed to be able to run a ".jar" bundle without setting custom options, remember?
Could not agree with you more there. Java just is not the write once run any language that SUN marketed it to be. It is close, but it ain't there.
what?
Do they have any other choice? ;)
So he's never heard of good programmers outside of Sun?
Well he can't have much real experience then so why should I care what he thinks?
It can, in theory, be faster. Sometimes you discover data that turns out to be constant in the end, but you don't know this until your program is running. A JITter can use this additional information to compile to machine code that is a lot simpler and therefore faster. If you then execute this piece of code lots of times, you can earn back the time spent compiling and then start to profit from it. I remember some work being done into some research which did this in C: it generated some C based on a template, fork()-exec()ed gcc to compile it to a shared library, dlopen()ed the shared library and then ran the code. Of course, you had to do this explicitly, but I think since the chances of actually having an algorithm that benefits from this is pretty rare, that's not going to be a problem.
That being said, Java has no way of hinting to the compiler "this is going to be constant for a long while now", or "I'm going to run this loop a couple of million times in a bit, you might want to JIT it real good". Without those, the compiler doesn't really have a hope.
Also, it's not a case of interpreted languages not being cool. Perl, Python and a myriad of other languages are all interpreted (or run as some kind of byte-code), and no-one complains. Then again, I've seen Java out-paced by many of these languages (most of which compile the program to byte-code at start-up faster than Java loads), which suggests to me that Java is just a poor interpreted language. If you've seen how JVMs work internally, I think you'll agree with me.
ascii art
The only Java app I used very much was Limewire, and that was slow as hell for four versions of Mac OS X. Even heavily optimized Java that I wrote myself ran slow. And don't get me started about the load times or the ugly window elements.
I'm in the hole of the broadband donut.
http://java.sun.com/j2se/1.4.2/docs/api/java/lang/ System.html#gc()
I've been using Java since '96 off-and-on. I've been on a J2EE project for the last 2 years. It's not a perfect language, but I definitely prefer it to C++ and Objective-C which I did in the early to mid '90s, and hopefully I'll never touch a Perl script again (I used to do some Perl--a most painful and ugly language).
What OS are you dealing with, and what JRE? I have Sun's offical XP friendly JRE here, and it's 28,501,412 bytes - pretty close to 30MB.
It might be slow but it's not slower than Python. Not even close. Yet, Python is cool. It's because Python is fun. Partisans of other languages will likely feel the same about their language, and they're probably correct, but I don't know many people that way about Java.
I rarely criticize things I don't care about.
Best. comment. ever.
You may want to think about why software isn't written in java. One when you write software you want to make it available to as large a group as possible. Most computers don't have the JRE installed on them. This causes the issue now the person who wants to use the software needs to download the JRE also. As for it not-really-portability this is just nuts, I was part of a research grant that wrote a application in java. It was written on Solaris, run on Windows, Linux and we purchased a powerbook to check the platform independence and low and behold it ran on that also.
So for all you fashion victims out there: white is the new black, Moto is the new Sony, C is the new B, my sig can beat up your sig.
<fx: retch>
>>"Visual Basic was meant to be easy, for the masses"
First, there's nothing wrong with a language being easy to learn and easy to use. Power and ease of use are not mutally exclusive.
Second, what's with this stuff about languages "for the masses"? VB programmers are programmers. No one's running down to the local curb store for a loaf a bread and a $400 box of VB.net. MS hasn't included Basic, Visual or otherwise, with its operating systems since,I dunno, DOS 3.3?
-- Slashdot: When Public Access TV Says "No"
I used ACE for a previous multithreaded server and the project was very successful. We developed on Linux and FreeBSD but had no difficulty porting to Solaris, and could have ported to Windows with a couple of days of effort (we had use the occasional POSIX-specific idiom, but this was our own fault, not the toolkit).
The author, Douglas Schmidt, is a well-known standards wonk and performance freak -- an interesting combination that results in a kit that provides full cross-platform support while running hard with C++'s approach of "you don't pay for it if you don't use it." The kit included a full CORBA ORB that supported realtime operation (ie, bounded maximum delay).
Probably the best compliment I ever heard about ACE was a from a very senior coworker who commented that ACE was "not bad, for C++." Trust me -- from him, that was high, high praise.
Having said all that, when I have to share the tree with other developers, Java is my favorite mainstream language.
some programmers use it to store session-specific data
Then they are only pretending to be Java programmers. Session state is kept in the session object - what the hack do they think it's for? Servlets shall be stateless, possibly unless declared single-threaded, but noone is that stupid.
You cannot force garbage collection. From the API:
[Emphasis added.]
Java is faster than perl, python, ruby, and PHP
As JIT technology matures for these languages (like psycho has
for Python), statements like the above become less and less true.
If you want speed, use C or C++. Enjoy debugging the pointers and memory leaks
What are you doing with pointers that you have to spend any time at all
debugging them?
*sigh* back to work...
I agree with all of your points except the one about exceptions. You said:
"Exceptions. I'm trying to think of a modern language without exceptions. Hell, even C and Forth have exceptions."
I think he was talking about useful exceptions. Java has a real nice way of handling exceptions, and since it is GC'd you don't have the same hideous problems that you do in C/C++ with memory allocation.
Personally, the reason I think that Java sucks is the same reason I think most languages suck:
* No macro system
* No closures (you _can_ do closures w/ objects, but it's REALLY UGLY)
* No continuations
* No tuple-returning functions (this increases code size by about 50%)
Of those, the lack of tuple-returning functions is probably the biggest practical issue on a daily basis. For example, with Perl, I can grab a row from a database query like this
($firstname, $lastname, $zipcode) = $sth->fetchrow_array();
In Java (it's been a long time, so this isn't exact) it goes something like this:
row = statement.getrow()
firstname = (String) row.element_of_row(0);
lastname = (String) row.element_of_row(1);
zipcode = (String) row.element_of_row(2);
And that is just a waste of life and breath.
Macro systems (true macro systems, like Scheme's, not crap like C/C++ macros) are nice, because they allow you to emulate just about any feature of any other language. Scheme doesn't have exceptions, but you can combine continuations and Scheme's macro system and make exceptions. Scheme doesn't have dynamic variables, but again you can build them w/ macros. Scheme doesn't have tuple-returning functions, but you get the picture (hopefully).
Continuations are _really_ nice in complex code, but they aren't that necessary on a daily basis. They are more useful in behind-the-scenes functions.
Closures are pretty darn useful, but you can usually code around them pretty well if you don't have real ones.
If you haven't noticed, I like Scheme because it has a few really powerful features, and the macro system can be used to stitch these features together into just about any other feature of any other programming language.
Engineering and the Ultimate
- Stripping comments.
- bz2 compressing.
The dynamically typed language is less than 10% the size of the java implementation.When complete it is going to be, at worse, 20% the size of the java implementation.
PS: The symbol names used in the dynamic language implementation aren't terse.
Seastead this.
Java is used in MANY thousands of enterprise applications at Server-side. Why do you think WebLogic, WAS 4.0 and even OC4J sell so much?
Java is manna for banking industry.
"Doing what i can, with what i have." ~ Burt Gummer
Different architectures will use different amounts of memory for stuff. If the developers have to worry and deal with all this stuff, it isn't much different from doing the same sort of things in C or C++ (worrying about 32-bit vs. 64-bit integers and the like).
From my experiences, Java being cross platform is one of the major myths about Java.
Don't mistake popularity for technological superiority.
After all, Windows has a 90% market share.
It's been a long time.
Being able to recognize and prevent security holes are the mark of a decent and seasoned programmer. Javas hides this from the novice programmer.
As for unmaintainable code, this can happen with *ANY* language. Again, preventing this is the mark of an experienced programmer.
Both Java and PHP have cross platform issues no matter how you slice it. Again, the familiarity with the language keeps these down. You are not the only one who has written cross platform applications and had them run on a variety of platforms. I have built PHP apps that run well anywhere you put them. I have also seen Java apps that won't run anywhere but on the platform they were developed on. This is really a stupid point all around!
As for the library issues, PHP suffers from the same, so does Perl. CPAN has some crappy and nearly useless libs in there. Again, a stupid point.
In the end it comes down to programmer preference. I like PHP, you like Java, in the end, does it really F**ing matter what you use, as long as it gets the job done?
Look, for example, at Eclipse IDE. Eclipse is a Java app, and its extremely powerful and not very slow. Why? They use their own widgets that have less overhead, they are not using Swing widgets.
And then you use Borland's JBuilder, which is a Swing app, and see it's not slow either. It's not the library that's the problem, it's how you use it.
frankly, this is a somewhat naive point of view. java can leak memory just like any other language. sure, you wan't forget to free something, but java might if you leave it lying around in some persistent collection. sure, you might not have header files, instead you have interfaces which allow different classes to depend on each other. java does alleviate the problem of pointers, but it has plenty of other problems it introduces. the stuff you mention isn't "crap," it's just that java masquerades most of those things to make it easier for simple projects. as the size of the project grows, java has as many problems as other programming languages.
BSD is for people who love UNIX. Linux is for those who hate Microsoft.
I just went to java.com and went to the manual download page (since the automatic page detected I have a JVM installed) and the "offline" installer I downloaded was 15,633,128 bytes (14.9MB, if you just want to toss numbers around). The net installer package was about 1.5MB. Where are you getting this 27MB number?
True. An example of this would be FoxPro (grr, I mean Microsoft Visual FoxPro), which compiles to bytecode. It's extremely fast, but Windows-only. I'm sure the design tradeoffs made in it were different then those made for Java.
:-)) I envy VFP's built-in database manipulation commands.
I've programmed extensively in both and like them both for different reasons. Whenever I need to access a data source in Java (which is right this very second if I weren't posting on Slashdot
My dislike of Java has nothing to do with slowness. It has to do with control and succinctness. Trivial example:
// Must be stored in a file called "hello.java"
public class hello {
static public void main(String[] argv) {
System.out.println("Hello world!");
}
}
Since everyone likes readability, I'd like to ask what part of "static public void" helps you to understand the program. Let's compare this to, oh say Perl.
print "Hello World\n";
Which, as Perl's reputation precedes it, is obviously harder to understand.
Javs relies on vast ammounts of knowledge drilled into the heads of students. If the OO paradigm wasn't so popular, Java would be entirely obtuse. Anything not memorized must be looked up. You wanted to add that integer to the float? Too bad. Go look it up type converting. Additionally I'd like to conjecture that the human mind is better at remembering small things than large ones. Therefore, system.out.println() is more difficult to remember than print. I'd rather remember something like "-e" (Perl) to test for file existance, than the Java equivalent, which I have looked up and since forgotten (though I've used each the same number of times).
While C may be verbose, it allows you to have near complete control of the physical operations of the hardware (e.g. when you delete memory or use a pointer, this has a physical analogue).
Java is both verbose (lots of commands to do simple stuff), clunky (really long commands), and forces you to use the OO paradigm whether or not the problem demands it. It's these reasons why I dislike it.
-- Political fascism requires a Fuhrer.
It's a bit shortsighted to assume that Java magically makes bad programmers less risky.
Uhm... but it does. It doesn't make them good coders, of course, but it does substantially limit the damage they can do, compared with C.
I'm reminded of a humourous quote by Bjarne Stroustrup, which was something to the effect of, "C makes it easy to shoot yourself in the foot. C++ makes it harder, but when you do, you'll take your whole leg off."
Like woodworking? Build your own picture frames.
"Another possible reason is because C/C++ has to free up memory as it goes"
It doesn't have to. You could have a global list of pointers you've used and free them all up at the end or every given time period a la java.
"Bullshit. IME..."
Oddly enough I was pointing out that comparing Java's platform to a language specification that is implemented differently for each platform it runs is a better cost-benefit analysis than simply saying, "Good luck pointer jockey"
At no point did I elude to the fact that C or C++ hackers who know what they are doing don't have problems. Am I to infer that Java developers do not have problems? No - you qualified it by "Java lowers the bar somewhat" BUT my original meaning seems to be lost.
Bullshit indeed.
BSD is designed. Linux is grown. C++ libs
You mean you own a TV?
Ironically, the word ironically is often used incorrectly.
First, there's nothing wrong with a language being easy to learn and easy to use. Power and ease of use are not mutally exclusive.
True. But sometimes "ease of use" runs into "quick and dirty", and all the difficulty in maintaining and extending that that implies. VB and Perl lend themselves to quick and dirty and require more self-discipline to stay well-engineered. Java usually pushes you to more forethought, and while crap code is certainly possible, it's somewhat less likely.
Second, what's with this stuff about languages "for the masses"? VB programmers are programmers. No one's running down to the local curb store for a loaf a bread and a $400 box of VB.net. MS hasn't included Basic, Visual or otherwise, with its operating systems since,I dunno, DOS 3.3?
Yes, currently VB is just another language.
But I grew up with built-in BASICS, and when I got introduced to it, VB3 seemed to be positioned in a similar role. I got a student edition for cheap and had a lot of fun.
As for the "for the masses", that could also be "for the non-techie, business-knowledge people in your company". I don't know if VB (especially the Office-centric versions) still do that well or not.
I do think that we who grew up with computers that booted into BASIC have an edge over people who get the start button. Making goofy, kiddie programs had a much lower barrier to entry back then...now it's almost certain you'll have to install something, or go nuts with the Javascript.
SO YOU'RE GOING TO DIE: The Comic for Dealing with Death
I agree that Java is not the best on the client for the reasons you list. There is a time and place for it, but honestly deploying Java apps to the desktop should be verboten! Leave it on the server and let your users use their familiar web browser to get work done.
Blar.
here is the REAL reason hackers don't like java, and most of them don't even realize it.
the job of an organization developing a software product (whether it's a company, an open source team, whatever), is to get a product out. nobody outside the project cares about languages or anything else, as long as it all works in the end. but to get a product out, the manager eventually has to pick a strategy. they usually fall somewhere in between the two extremes:
A) use a few brilliant (possibly well paid) hackers and let them do the work. they're smart, and good enough to rely on to just do it. managing them is like herding cats, but why would you need to?
B) use an army of keyboard monkeys and manage the hell out of them. these guys can pound out mediocre code, but with enough software engineering from the top down, well defined specs, and massive testing and integration, their work is sieved into a release-quality product.
real hackers hate being marginalized, having their creativity stifled (yes, for those of us who actually write code, not just implement specs, creativity is involved), having to do the dumb solution just because everyone else is too weak to do their part of the smart solution.
java is not a bad language. i think many would agree that is it at least decent (i think it's pretty good, actually). but java is the language of the B coders. it is made to be easy and idiot proof, like visual basic. you cannot do "neat hacks" in java, because if you could, the B coders would screw it up and produce worse code. java is a great language for the B coders. but the choice of java for a project is often a leaning toward strategy B. it's the "we can get any code monkey off the street to do this". it's the grunt work software that real hackers don't want to do, and what B coders are hired for.
perl, a RAD (and rad) programming language, does not suffer this stigma. perl is accepted by hackers, precisely because it is not idiot proof. it's easy to confuse the B coders (and yourself) with some maliciously written ascii barf. you can do some crazy tricks in perl. it does not lend itself well to software engineering and the micromanagement of the B coders. perl is a hacker's language.
many real hackers i've seen instinctively feel resentment towards java and the like, because they see marginalization of the software industry. java is for the blue collar coders, part of the greater plan of "software factories", where reproducability, meeting deadlines and specs, and easy replacement of people is way more important than doing cool shit. those of us who wish to stay at the top of the game, to do the cool shit, to write the programs that interest us the right way are often drawn to the languages that keep out the idiots, that have a higher barrier of entry, and let us do the cool hacks.
i don't dislike java, and i don't dislike you B coders out there (you know who you are). i just don't want to be one of you.
thanks for reading my long-ass post,
p.
you just stepped on your arguments from the original posting... thanks for that ;-)
First of all, Java!=JVM. Please make this distinction. I won't discuss the pros and cons of Java as a language here, just the JVM. You can use gcj to GNU-compile Java and you'll get very close to the performance of GNU-compiled C++ which is what one would expect. Note that I said GNU-compiled because there still commercial compilers which produce better code, in terms of execution speed. [Of course, I hope GCC will overtake them, but that's an unrelated issue :)]
:)
:)
Mod me troll flamebait, whatever - but the JVM is slow, not only on start up.
The empirical argument
IMHO, todays average real world JVM app *is* slower than the average real world compiled app. And, no, I do not talk about the startup time only. GUI code is slow. Network/File I/O is slow. Show me a JVM app (app, not test case!) with a native compiled equivalent which is slower. You won't find any.
MAYBE there is the *theoretical possibility* of JIT being faster than compiled/hand optimized assembly code. But this is purely theoretical. I have yet to see real world apps and not some made-up testcases with matching peephole optimizations for a particular architecture where this is the case. There are still uneccessary virtual method calls, wasted stack space etc. in JIT code.
The theoretical argument, mixed with personal opinion
Doing JIT with JVM code involves steps very similar to decompilation [JVM->IntermediateCode->Target] because in JVM code, no information about higher-level structure is preserved. This reconstruction is computationally very expensive (google: decompilation problems) so only approximative algorithms are used, leading to non-optimal code. There are reasons why e.g. the ANDF format preserves much more information than JVM code.
A possible solution
I think LLVM is a nice project that could bring all the VM hype of Java to C/C++/CommonLisp/Perl/Python/BiglooScheme etc. And Java!
Sure LLVM still lacks many things, the VM code isn't much more descriptive than JVM code etc. But it is independent, and it is growing. An LLVM applet plugin for Mozilla would be nice
This is also a partly political thing. Why do FLOSS Java developers accept the fact that Java and JVM are so tightly coupled? Maybe this helps Sun's goals (to spread the platform Java) but technically, it is clearly an inferiour solution.
The first sentence above contradicts the one that follows. Java code can hardly be portable if it won't run at all on most potential users' machines.
On machines that are already burdened with JREs, how can your program pick from among them all which one to use?
Right... So cos a DEVELOPER did not know how to use the language/platform, the language is shit...
Mmmm.....
Wow, I should not post when knackered.
...and many still do if they are more efficient with it.
Blar.
Sigh. Being the oldster I am I thought the nonsense of mine is bigger than yours had died down.
This is the followup to a piece of hero worship (very much in the spirit of U.S centric culture) of the "Great Hacker". Oh where is this mythical beast? I see him not, yet I have longed to meet this wise and omnipotent entity.
Foo. Here in Europe we don't believe in such junk.
I've met some fine artisans, and some really unpleasantly egotistical f**ks as well. Sometimes they seem to be one and the same entity. But like
male cats you can't exist in the same arena without risking some nasty matter anti-matter collision...
Twenty plus years of avoiding cobol (deliberate lower case) and other crocks and I'm still reminded of that line in Blade Runner:
"I want more life f**ker"
Here in Greece, you could end up homeless for two years or worse just *trying* to be a hacker. Believe me. I've spent more time feeding the doves and educating the locals here in athens about dove culture than programming...
Hope nobody remembers this post...
To put that passage in context, he's talking about a bottom up approach, and how the "great hackers" should be used as tool makers, building the Duplo blocks that the less talented people can use to assemble applications.
Have fun with your Lego.
I'll look into it. It's bugged me about C++ that I would need to write different OS-specific libraries for a bunch of stuff.
Cheers
Lost at C:>. Found at C.
In my experience (which isn't huge with Java, but I've used it for commercial work), one of the things I liked most about Java was that it actually tended to save me lines of code.
Oh, sure it's got an explicit full-on syntax, but I'm comfortable with that. What I was most impressed with was there was a vast amount of standard data types and APIs available to accomplish a very huge amount of stuff. Looking at C++ and the like, the APIs are anything but cross-platform. (Any helpful links to a good C++ API (not GUI toolkits) which is both POSIX and Windows might make me use that some more.)
Ding ding ding! We have a winner! Congratulations, you realized that a terse language is not necessarily a productive one. If that were true, C would be more productive than Java, and APL would be the most productive language on the face of the earth. Neither of those statements is true because the terse languages have primitive standard libraries and therefore usually require more code to accomplish the same thing.
If you want all the nice Java libraries, strong static type-checking, and compilation to JVM bytecode, why not try Nice or Scala? Both provide everything Java has, including the ability just to use arbitrary Java classes and APIs completely transparently - and they add many of the best features of functional programming, and have terser syntaxes than Java too.
Worth considering, anyway.
There are Python libraries that have platform specific behaviors, but at the
app level, something written in Python will behave the same on any platform
it's run on.
*sigh* back to work...
From the article link in question:
Server Error
The server encountered an internal error and was unable to complete your request.
Could not connect to JRun Server.
Obviously, the Slashdot effect has brought pretty much every language to its knees and depends more on the hardware than the language the app is written on, but when the server hosting a page defending a language is itself run on that language and generating errors, it makes me laugh.
In all seriousness, on problem I have with Java as an end user is that many Java apps seem to be coded to a specific version of the JVM such that even subreleases from the same major (or even minor) version of the JVM will cause the app to not run. Ciscoworks is one of these. It drives me nuts havibg to have 2 or 3 versions of the JVM on every computer I use simply because one Java app or another is REALLY finicky. I don't know if this is a problem of Java attracting/creating bad programmers (as posited in the article this story is responding to) or if the JVM developers have no interest in backwards compatibility.
Other than that issue, I, as an end user, think Java is great. But then again, I program mostly in PHP or (*gasp*) Visual Basic (including VBA and VBScript), so I'm not really qualified to discuss what languages are a "real man's" language.
Oh, was that my outside voice?
I guess I'll never make anyones list of greatest programmers, but I think Java is plenty cool, especially with some of the recent changes. Java has gone from being a trivial scripting language that was primarily useful for animating pictures on the web to a very powerful language that can occasionally outperform C++, especially on web appliations.
Java is far easier to learn than C++. While Java does not provide all the flexibility of C++, most of the time I don't need to be able to write code that interacts directly with the hardware.
The days of managing memory by hand should have become a distant memory for all but a handful of programmers long ago. Memory management bugs are among the most common and difficult bugs to fix.
When I first started programming Assembler programmers made all the same comments about us "sissy" C programmers that the C++ programmers make about programmers in Java and other memory managed languages. There aren't so many assembly language programmers around these days...
-All that is gold does not glitter - Tolkien
www.ra
I'm all for choosing the right tool for the job. But there are still a couple problems with this. First, there are plenty of valid choices to make for modern applications, which are so often web based these days. Second, the choices being made are done by business managers without consulting the technical staff, often before they've even hired any. Java seems to be the most common choice among the business people, with Perl and PHP coming in a distant second and third. The reason I believe so much Java is being chosen is not because of any technical value (which it does have), but because it is being sold to managers by sales people from companies like Sun and IBM. In other words, the decisions are being made "behind the backs of real programmers", despite the fact that in most cases Java would be a fine choice (as would a few others), anyway. It seems to me that there is some resentment against having non-technical people forcing a technical decision, made for non-technical reasons, on technical people.
now we need to go OSS in diesel cars
Anyone who has worked with budgets in large corporations can tell you Developer/Tester hours are generally the majority of the budget. Hardware is a drop in the bucket (and you can even capitalize it). On many projects I've worked on, Java has driven the people cost down resultig in a net savings even though we may have had to throw a crap load (official Business terminology) of CPU/memory at the application.
Oh, it will fail alright -- but not before you've gotten your promotion and left the company. Who cares that the company will itself be left with the unanalyzable miazma produced by having 5 to 10 times the code in Java that you would have had if you'd simply had decent code-reviews and used mature Perl programmers. Well, the stock holders care but who is going to call them about your references for your next job?
Seastead this.
Open source cross platform C++ libraries include Boost, ACE, STLSoft, and Loki to name a few.
You should give Python a try as well.
Sorry my bullshit sensor overloaded.
I've recently completed a Python-based office app. It used Excel for data gathering, through COM, and it wrote reports in Word.
Advantages? It's free, you get to use the same documentation as for Vbasic (the Office help files) and the language is cool and easy to learn.
I'll do the stupid thing first and then you shy people follow...
-Djava.ext.dirs=/your/dir/here
Done.
Cheers,
Ian
All with the servlets, enterprise javabeans, setting up the whole mess, and the fact that the free available java environments are _NOT_ the ones you're using at your job. They're just used for "training" (well that was one or two years ago - but I got a php job and i love it).
To get a good handle in this J2EE not-quite-multitier mess, you need HEAVY training ($$$), and of course, the ones who really get money are Sun.
Where I live, there are thousands of vacancies asking for people with two years experience in J2EE. PHP? No, thanks. "Eew... hackable, for newbies".
Still, I can setup Apache, PHP and mySQL in a couple of hours (INCLUDING downloading), and start testing with source code right away. Try that with Java.
The real reason why J2EE is "cool" is because Sun gives FREE Java support to those who purchase their computers. It's just like Microsoft, but without the monopoly (yet).
If the time that one invests in java training would be used for PHP / MySQL (including multitier programming), things would be quite different.
Nice post. +5 insightful if I had the points to give. I fully agree that Java is a great language if you don't want to put your higher thought processes to work. You can get away with looking at a spec sheet and punching out a "plug in the code to meet the specs" scenario. There is no, "let's Make A and B work, and in doing so, supercede the need to put in C" and make it better, with less code, better reliability, and less common errors.
Raging in an online forum won't do anything for the world around you. To see change, you must take action.
I don't know why everyone wants to slag off a language which was designed to be a minimalist approach to getting software portably on set top boxen...
Yes, I prefer C# (aesthetically) , assembler (for control), C (for a reasonable trade off), Wirth languages (for attempts to make braindead cattle capable of programming), (write the rest, because I don't have enough space in the margin...).
Why the need to make this an interminably boring and dull debate? Next you'll post that CowboyNeal needs a spell checker or Michael has the repeats repeats repeats or that puke yellow isn't your favo(u)rite colo(u)r on slashdot...
Oh. Sorry. It's August isn't it. We have to watch the olympics (R)
(worth the mod down?)
Stop eatin the beans mike?
Maybe Java is considered so un-cool because it has a crappy name. Of course, we all like our coffee, but "Java" as a name is rather lame. It doesn't have the same ring to it as "C", or "perl".
:)
Seems to me that all the "cool" languages have either really mysterious names, or "shiny" ones. Try this out:
"I'm a C programmer" (add ++, even cooler)
"I'm a perl programmer"
"I do Ruby."
"Python is my language of choice"
then, in a squeaky voice...
"Java is the coolest!"
doesn't work for me, man.
This is not really about Javas coolness or not (could not even read the article).
To my experience when Java programmers switch to C++ they tend to produce code that is full of memory leaks (new in Java and C++ are VERY different) and have a tendency to write overdesigned and unnecessary complex code.
What you will always see from a person done Java in the past and now doing C++ is things like:
HaraldOK, that's a fair point. I never used C's exception capability; I've always kludged up signals for that sort of thing.
Let me just say a thousand times "Amen", especially about closures. I honestly have no idea how people get by without them. Closures and tuple returns are why I do all my work in either Lisp or Forth depending on how much I need to control memory allocation and how little I need to manipulate character strings.
You're exactly right about multiple return values and code size: single-return-only languages require you to either design a structure or class (increasing program size) or pass an alterable reference (increasing program fragility) any time a function has a more interesting answer than a single primitive type.
Personally, what I can't seem to program well without are:
I'm not sure whether that speaks more to the kind of work I do or my particular weaknesses as a programmer...
All's true that is mistrusted
when considering how few people can design a good database schema! Sadly, the same college newbies hired for the Java skills get stuck looking like deer in the headlights when dealing with storing their darn data. Remember, kids, when you see fields like email1 and email2 in your design, sit back and think about the pain you will cause when someone needs email3 (i.e., you need a different solution entirely).
-- "Makes Little Debbie look like a pile of puke!" - Moe Szyslak
ummm because java sucks and no matter how of them mhz you got, its always going to be slow as s**t!!!
There is *no* way that a interpreted or JIT compiled language can be *faster* than native code.
Nope.
There are actually quite a few ways that an interpreted language can be faster than native code.
If you were right, then VLIW processors would've taken over long, long ago.
It's important to realize that the instruction set that any processor uses is not its native instruction set, for a long time now. Ever since the Pentium days, there's a "instruction decode" step in the pipeline, and even PPCs use it to pare down the (comparatively simpler) PPC instruction set to something more RISC-like.
So what does this have to do with programming languages, you might ask?
The point is that the analogy is exactly the same: VLIW processors rely on the instruction stream being very parallel, and well tuned to the architecture so that they can be very simple and very fast. There's only one problem - compilers can't be that smart. You don't have all the information until the program runs - this is very similar to the Halting problem. Until the program runs, you don't know how it will behave.
So what you're saying is "I don't see how an interpreted language can be faster than native code", likely because of the overhead. The answer to your "how" is that the interpreter - like any modern x86 computer - has more information available to it while its running than the compiler had when the program was compiled. Therefore the possibility exists that an interpreted language can outperform native code, because it can optimize for cases that the native code cannot. If that optimization is enough of an improvement over the overhead, you win.
It is for this reason that modern x86 computers perform so well compared to VLIW architectures - it's very difficult to extract parallelism from the code itself, before it's executed. It's actually more efficient to extract the parallelism while the code is actually running.
This is the exact same reason why Java can beat C++, in certain cases. And for benchmarks, http://cpp.student.utwente.nl/benchmark/. Note that this is in fact someone improving upon a C++ vs Java benchmark that showed Java won, so this is C++ striving as hard as it can.
Here you can see that for certain cases, Java can win. The most notable one is the nested-loop benchmark, where the Intel C++ compiler ran in 1.8 seconds, and the Java example ran at 1.05 seconds.
Your next statement might be that "yes, but in assembly..." and I will then say that yes, I highly doubt that you can find a Java program that will beat a hand-assembled piece of code. But it still is *possible*, because the interpreter may be able to perform some optimization during runtime that the person doing the coding can't because it's not strictly correct - this is akin to a branch predictor in hardware. It's allowed to cheat so long as it's later proved that it was right, but then pay a penalty when it's wrong.
Java, the language, sucks, but yet has made huge inroads into commercial realms, supplanting COBOL and other languages as the language of choice for business applications. And it's a shame, as there are loads of shortcomings, that offset the advantages of Java and the JVM deal:
But the programmer != the tool. It might make it more difficult, or more lines of code, or more kluginess, but a talented codesmith can work with primitive tools too.
AZspot
(not kidding here)
#1 reason why Java is UnCool: JavaScript.
JavaScript has nothing to do with Java. But Java was victimized, bent over, and abused with a pointy stick in order for some marketing jackasses (company not named) to make a quick buck trying to confuse people.
These are my friends, See how they glisten. See this one shine, how he smiles in the light.
It is not slower than C#! (for non GUI stuff). How did you get this idea? Can you provide some hard benchmarks? I have seen some and did a number of benchmarks for myself, comparing .NET 1.1 C# to JDK 1.4, and in most cases Java was faster.
It is very irritating to see repeats of such blatant lies trying to engrave these myths in peoples minds.
if Sun doesn't like it, it's dead.
... that are vague because of the politicking in the comittees. "Left to the implementation", anyone? "Left for further study"? That's not a spec, that's a suggestion. And I won't even mention SQL, which is almost actively ignored as a standard.
Sorry, but that's untrue; there has been at least one feature added to Java that Sun was against. All Sun has is a permanent seat on the JCP Executive Comittee, and the same veto any other member (like IBM) has.
vendor-independent standards
it's not open source
Nor are AT&T's C or C++ implementations. Does that mean they cannot include GCC? The major difference is that C++ isn't trademarked, so you can call anything C++ and get away with it. My, how "standard".
Why must Sun's implementation be open-sourced? Isn't that just the OSS community saying "woe is us, we can't write a good implementation of the FREELY AVAILABLE SPECIFICATIONS, plz help us"?
a little more painful on clients for client applications
No, it's just as easy to make installers for Java apps as for "native" apps; Vise, InstallShield and InstallAnywhere all have flavours for making Java installers if you don't want to use Java WebStart.
Also, the programming languages that shipped with old computers were generally considered "essential" to use the operating system - there has been a shift away from that by having users switch over to a CLI or GUI rather than have them understand how programs work.
Nowadays, those programming languages are no longer necessairy - and perhaps that's a good thing. Although it was impressive that I could type 'Load "*",8,1' at the age of 2-3, it's something that could have been a bit simpler and faster with a GUI (assuming the had the processing power to support one.)
bound checking is removed dynamically by JIT if it finds there's no need for it. So having a'debug' version isn't really necessary.
if (!signature) { throw std::runtime_error("No sig!"); }
I posted this on my java web browser!
You are aware that there exist garbage collectors for c/c++?
.o files tho, so it is after compile time. THere is however no theoretical reason why you cannot decide at that time to recompile a bit of code to get the exact same optimizing as you could with java.
Also, in the example you give, you can know that a virtual method is never going to be overridden before runtime, you do need to link your
There are other cases where you can't tell things untill you are actually running the code, and java can indeed have a performance advantage there that is only possible in c/c++ when you do extensive profiling and debugging (to see what is really happening) and direct the compiler properly by correct hinting.
That hinting is something you cannot do in java, so well.. it depends in part on the code and how well it takes advantage of the specific environment.
For java you have to do less work to get the best performance then for c/c++ for some situations.
Perl and Java are kindred spirits. They both compile to bytecode and run on VM's. They are both highly portable unless you use something OS specific. They were built for different reasons and definitely have different streangs but their architecture is similar. The language of perl5 predates Java and is slightly less advanced in many ways but they got many things fundamentally right that Java got wrong. The changes in the language for perl6 have fixed all the glaring issues I've seen with the and has added lots of new improvements that make it make it an example of how to do a language right.
From what I've seen, perl6 the language is superior to Java the language. It remains to be seen how perl6 the platform will compare.
set softtabstop=4 shiftwidth=4 expandtab nocp worlddomination
You still have to know to put the pointer in the list, which inserts inline code on many paths. (Maybe not as heavy as a call to free() or delete, but it is more code.
A better strategy for some apps is to have "arenas" that you allocate from for certain phases of processing. When you're done with objects from that arena, just forget the pointer (a'la Java, where you just drop your references to an object), and when that phase of processing completes, just reset the entire arena in a single step.
--JoeProgram Intellivision!
I have said it before, I say it again...
Guess what's the most popular BitTorrent client is written in? Java....
http://sourceforge.net/projects/azureus/
Drill baby drill - on Mars
That's true; but I don't know anyone who does that.
Consider that the "several instructions" to which a VM instruction maps can be hand-tuned code, whereas the compiler has no idea what we will throw at it and often produces code that we could improve. At the same time, the designer of the abstract architecture doesn't have to deal with icky real-world electronics issues and can spend more of his time designing something for which it is easy to compile well.
(OTOH I learned a lot about code tuning on the PDP-10 from reading the output of the Blis10 compiler. What a humbling experience.)
assuming you are doing server programming, you might find ACE helpful.
2nd that. I've used ACE on Winnt, Solaris, HP/UX 10.20 and 11, and Linux. I'd also recommend reading Schmidt's various papers on design patterns. Many of these are implemented in ACE and greatly cut down on design/coding time as well as bugs in the code.
FreeSpeech.org
Yes, you can use /etc/ld.so.conf
for common shared objects. You can equivalently
use $JAVA_HOME/jre/lib/ext for common jars.
Using a path is the single most common way to find dynamically loaded code.
(Reality reasserts itself sooner or later.)
No, you only need to use the -Xbootclasspath parameter when you want to replace one of the standard libraries - say to put some debug code into the Object constructor.
OK, so here's my list why Java *is* cool and is used by great programmers:
1. It runs everywhere unmodified. This has got to be the coolest thing of all, and the reason I adopted Java in the first place. At the beginning this was not always true, due in major part to the AWT graphics libraries, but today it is.
2. It's more productive to work with it, leading to fewer bugs. This is very important in business apps. I certainly no longer get C/C++ pointer problems, memory leaks, or perl syntax error problems.
3. It is fast (ok, it loads slow the very first time, but with JDK1.5 this seems to being addressed as well). Somehow Java lends itself so easily for users to write efficient code (i.e.: multithreading is a snap and platform-independent), that somehow the applications we've been replacing with it simply run at least twice as fast as the older C++, VB, and perl apps.
4. It is simple. Sure, some hackers like garbage-looking code because they think the harder to understand their code the cooler it is, but in my book the cleaner and simpler code wins any day, specially when programming in a team environment. I think Java should be given credit as the environment that brough simplicity back to programmers in the internet age (just as VB did in the client-server day).
5. You can use multiple tools to develop the same code base. Heck, and now with ANT (possibly one of the coolest tools in recent times) you can choose your IDE (or command-line if that's your thing) and move the project back-and-forth between IDEs to take advantage of each (GUI design, refactoring, etc). Choice is a good thing.
6. I'll repeat it again: How cool is it to develop in Windows and drop the app unmodified in Linux or OS/X and see it run as expected with NO changes to the code? Or if you prefer, develop in Linux and deploy in Windows. Either way it works.
7. It is standard. Sure, it is not open source but then again not everything has to be. I think the fact that open sourcers advocate freedom should be reason enough to allow other companies to choose if they want to free their software or not. It is their choice. The fact that it is standard means that Java is protected from the "Unix division plage" where now almost no Unix is compatible with any other Unix. Geez, even Linux is starting to become incompatible with all the different versions of itself. Sometimes centralized control is a good thing.
Oh the irony is killing me.
The code name for C# was Cool. Java is so un-Cool.
Bryan
CT
Its good you'll rise or fall with your decisions in an identifiable manner. What companies are you driving into the dirt?
Seastead this.
I look forward to JRE 1.5, then, but it's not released so I haven't used it for production work.
The language itself isn't that bad. It's Sun that's the problem. Java is a classic dot-bomb product - launched with great fanfare, given away, and heavily promoted. Of course it sucks.
I've used several Java apps, and eventually get annoyed by the funky "open file" dialog or the weird ListControl. And the non-standard coloring. Yes, it's cosmetic, but on a daily basis, it's annoying and tiresome.
Java apps stick out like a sore thumb, due to the unpolished and slightly funky user interfaces.
I'm just repeating what you said because you said it so well (and I feel this needs to be emphasized). You've nailed PRECISELY what I've been thinking for years. The conflict between "choosing the best tool for the job", the fact that there are a billion tools and being proficient enough in all of them to even be able to choose the right tool for the right job. As you said, reality is just not that simple.
Actually, I am a professional C#/ASP.NET guy.
But yes, I am ALSO a Java guy - the right tool for the right job you know!
And in the link supplied, much of his gripes was with the jar tool being slow compared to tar.
And with a Hello World program doing alot of extra stuff!
But those are things java really wasnt meant to do well!
THAT is why I find it silly to mod it insightful.
I'm a Java guy because of the API. When I want to get something done right I don't want to re-invent the wheel, and I don't want to have to mix and match dozens of differently-written APIs. Java features a robust and (generally) consistently named and structured API. On top of this, the API is very well designed and tested, and caveats are well-known. It is not some obscure OSS library that lacks security/features/functionality and may still have unknown holes or bugs.
Also, all this talk of the "Coolness" of a language really got me upset and made me have to post. When I was in college, people like this pissed me off to no end. I had a compilers class and the assignment was to make a 4-stage compiler in the language of our choice. I picked Java and recommended others do the same. The responses that I got were "I want it to be quick, so I'll use C" or "I don't really understand Java, so I'll use C" or "No thanks, I'll use a real programming language", etc. So fine, I was the only one that used Java. In the end, my program was complete, worked 100% without error, was well-structured (having logical distinction between subcomponents), FASTER than the C programs, readable, and it took me LESS time to write it than the C-lusers that stayed up until Midnight helplessly trying to complete theirs. Some failed.
In the course of working on the compiler project, the 1337 C coders had memory management issues, segfaults, etc. Some of them could not work the bugs out of their hashtables/linked-lists/etc, and so resorted to bad practices such as bubble-sorts, arrays-of-arrays-of-arrays (instead of dealing with pointers), etc. Wasteful memory practices, inefficient algorithms, sloppy code, etc. -- hallmarks of 50-75% of every C program I've ever had the pleasure to clean up after. The ones that
DID manage to complete their projects were exquisitely proud of how great of hackers they were. Nevermind the fact that in their desparate drive to complete the project, they had no chase to sit back and think of nevermind implement hash-maps, etc. which would make their program efficient AND ELEGANT. Java allowed me the comfortable leisure to do all that, and I have the elegant code to prove it.
Now before anyone gets me wrong and says that at least these guys were getting experience with the algorithm knowledge they'd later need, let me correct you. I CAN do algorithms and memory management very well. I understand data-structures perfectly and have written my own in C-based data-structure classes. Java's structures are well-thought-out and allows GOOD programmers to focus on elegance rather than re-implementation.
And BTW... every "1337 hax0r" I've ever met has been nothing but a sham. The smartest programmers I've ever met favored C/C++. The second-smartest favored Java. Both wore normal clothes and didn't have the long hair, beard, etc. that the rest of the insecure programmers of my school would cultivate instead of actual ability. They enjoyed elegance instead of minutae, and knew that languages were just tools to get a job done right (Where right is sometimes incompatible with fast). That should be the real definition of a hacker.
Sincerely,
Enemy of Cool
You're applying a technical solution to what is, essentially, a management problem.
It doesn't matter WHAT language is the company lingua franca - if you are not holding regular code reviews (and instead trusting the B&D features of Java to do it for you) you WILL get bitten by maintainibility problems down the road. NO language is so obfuscation-proof as to not require review.
Furthermore, if you fail to do reviews, then you are denying your coders a chance to improve their own skills. There is no better way to learn new tricks and techniques than exposure to someone else's code.
And finally, coders are ego-driven animals. If their code is going to be subject to regular review and (especially) public critique, they will go to much greater lengths to ensure high quality of their code than if the code is safely hidden away where only they can see it.
That's one of the major lessons to come out of Free Software - the more people who examine the code, the better it gets.
If you make code review and code sharing a major part of your corporate culture, you'll wind up with a far better and more motivated group of coders - who, incidently, can probably adapt to whatever language is the order of the day.
DG
Want to learn about race cars? Read my Book
If you disagree with me on social issues, then it's pretty clear that you are a narrow-minded bigot.
Mod me troll flamebait, whatever - but the JVM is slow, not only on start up.
Ive written quite a few java apps. The startup is the only slowdown I have really noticed. There is some comparison where a JVM, which has garbage collection and such, will be slightly slower than compiled. Have to stress the "slightly" comment since most of those processes are pretty well tuned in todays virtual machines.
Java developers have screamed bloody murder over this for years. Sun has promised that the next version release (1.6) of the JVM will allow for multiple apps within a single JVM. This would mean you could start the JVM once (like on system startup) and never have to pay that startup cost on a per java app basis.
Show me a JVM app (app, not test case!) with a native compiled equivalent which is slower. You won't find any.
You generally wont find an app written in both C and Java. Developers usually pick one or the other. Why write the same app twice? This makes finding good examples pretty hard.
This reconstruction is computationally very expensive (google: decompilation problems) so only approximative algorithms are used, leading to non-optimal code.
I dug around on google. Honestly I could not find someone to collaberate your statement. Do you have a direct link?
I think LLVM is a nice project that could bring all the VM hype
Getting a 404 on the link you posted.
Typically any slowness has been tied to poor garbage collector usage, and/or poor understanding of Swing.
I believe Java 'appears' so easy to write in, it entices people to write apps that really do not know what they are doing.
Apps I have written in Java going back about 8 years have run just fine and have had no speed issues.
New Java versions are bringing speed because they have improved GC behaviors, but still people need to write good code.
The reason why I love perl is its incredible concision and expressiveness. To me, Java and c# both suffer from beeing way too much verbose. This is not about laziness, nor about performances and/or compilation time; it's more about preventing the source code from beeing "polluted" uselessly. Better write comments than glue code ;)
>Saying Java isn't cool is like saying Scheme or ML
> isn't cool. It's just a personal preference,
No, Scheme and LISP (as well as modern ML varients) have features that are more powerful than Java. They can express things that cannot be expressed in Java, mainly code generation and modification at runtime, closures (Java has an ugly hack added for AWT), continuations, syntax extention, etc.
It is said that everyone eventually settles on some language on the power spectrum. You look at the features of your language and are reasonably satisfied. You look at simpler/less powerful languages and you wonder "how could anyone program effectively without feature x" (where x is one of you favorite features not available in the simpler language). You look at more powerful languages, and being rather satisfied with your current choice, say "What do I need feature y for? I don't use it now and see no reason too since I can program what I need with my language." (where feature y is a feature the more powerful language has and its supports make a great deal of hoopla over, whereas your language does not).
I was happy with C++, I could do amazingly strange and terse things with templates, knew the language well, etc. But then I met OCaml, and now I wonder, "how did anyone ever get by without discriminated unions, closures, currying, first-class functions, GC, a static type systems that actually works, etc.". Now don't get me wrong, several of those features you can emulate in C++, but it is non-trivial to do right, and not very terse, makeing you not want to do it often. And I know Scheme is more powerful, it has a better macro system and continuations, but alas, I may be at that point I mentioned above.
Another point i wanted to add is that Netbeans and Eclipse have both botched their GC behaviors. Both seeming to hope the JVM creaters magically create a awesome Garbage collector.
But sun has stated that this is not possible because the JVM can not know what the app or user is really doing and that running the GC should be handled by the application.
For me, its obvious. You run the GC in a seperate thread when all other tasks are idle. If you do not the JVM will run the GC when it gets full and bring your app to a screatching halt! Or you can do what server mode does and run the GC all the time slowing down your app all the time.
Bad decisions makes bad performance. Why Sun cant write an app to take into account the philocophy of GC of their JVM is beyond me...
he wouldn't. Java isn't cool. It isn't any less cool than any other programming language. Programming isn't cool; it's a way to avoid having to get a real job. Get a life.
This is true, except again in the government arena's special case. I can be fairly sure that the Department of Homeland Security is NOT outsourcing jobs to Pakistan.
:)
Bottom line is, if your college offers a co-op program to any three-letter agency, and you want to be set for life as a programmer, take a job there during college. Once you have your tickets, you're totally set.
I can speak from direct experience here - after 10 years (including the co-op time) my compensation has nearly sextupled, and I've always gotten to work on neat projects. No need to take the management track, either!
As to doing commercial-side work, I bet it is difficult to get experience. Too many people are going into "programming" because it's currently perceived as the hot path for $$. I've done more interviews with out-of-college folks with absolutely zero knowledge than I can count. All people should be looking for from a fresh graduate is object-oriented design skills, the capability to read UML, and enough working knowledge of OO languages to answer basic questions about polymorphism, inheritance, etc. The rest is OJT, and frankly, it's way better return on investment to train up a promising student into a senior developer than to try to poach one from a competitor. That's why my salary is so high now
Keep your friends close.
Keep your enemies in a little jar on your desk.
Sigh. Yet again. I won't read all of the postings but I'll guess that "it's slow.. It's constraining like a
chastity belt" come up. Well. Dumb. I ported the UCSD p-system to loads of machines in my dark distant past and yes it was slow. That wasn't the issue then. Hmm.
Seems to me that many of the younger folks out there haven't considered the benefits of executing on an imaginary processor.
1. You have control (yes: you can play nazi today!). In parallel (maybe co-operatively? Hey I like that paradox)
2. Script kiddies jump off the local landmark (example the clifton suspension bridge in Bristol UK) just because they can't get the immediate gratification they figured that they would get from watching that anime cartoon...).
3. We have horrendously kewl CPU's doing squawt most of the time. I don't care if my machine discovers E.T. (who wants to meet E.T?). I want to have a meaningful discussion with the Admiral from
Romulus or Mr. Spock.
Sorry. I watched all of this the first time out. I guess I haven't matured at all...
(hick. Another glass of metaxa methinks...)
Java vs C/C++ is the wrong comparison!
:-)
C/C++ is great for embedded work, its the perfect abstraction for what you do in assembly, but this isn't what the "cool hackers" are doing these days.
They are doing higher-level applications with more abstraction. At this level Python/Perl/Php are extremely flexible/powerful/easy to use.
Before you drive your camry make sure you check out the saturns
I like Java as much as anybody but I agree with the previous poster and admit it is not really very cross platform compared to many other languages.
.NET work on many platforms including BSD and I remember MS even released a more official implementation for BSD called Rotor. Like I said I am a big fan Java and would love to see Sun change the attitude and help make Java a truely cross platform system.
I notice you did not put any of the BSDs in your list. You can't just write off BSD as dead either. Yahoo and many hosting companies run it as their primary OS. Yes, I know there is a JDK for FreeBSD which you can build yourself, but how many big companies are going to go for such a solution. Also, JVM speed is still a major issue on BSD. Languages like Python, Perl and PHP are far better supported on BSD as well as many other UNIX platforms that may be considered too obscure by Sun.
As for C# I believe Mono and Portable
cf Subject.
Try Corewar @ www.koth.org - rec.games.corewar
the last time I checked it lots of "hackers" used it, heck look at the jakarta project, 95% of the code the apache foundation produces is java related. java is an interesting language if you go for true multiplatform, it is a really interesting language if you are interested in total stability and design issues and software engineering, it is a lousy language if you want to do low level systems hacking, that basically sums it up.
One major aspect of "Cool" not discussed yet is how Java may enhance one's paycheck. In the past, a number of "skills du jour" have motivated employers to provide higher pay to those having those skills.
Unfortunately, Java is probably not "Cool" anymore on this score. When I read the Sys-Con article, I noticed advertisements for $10/Hour Java Coders. Java is definitely not a "cool skill", at least in money terms.
Java forces people to use objects for everything. While this can be a pain to write short programs, in the end this can be a real help in environments that require many people to work on a project. The software architect can easily design a class heirarchy that will be strictly adhered to because Java forces. Interfaces can be used to ensure that certain methods are implemented. Also, the exception handling speeds dubugging. Many of these things are not cool and prevent neat tricks that border on shameless hacks. However, they help enforce a compliance standards and make software easier to maintain.
Maybe because I'm young and went through college with Java being the language of choice, but a null pointer exception beats a seg fault anyday!
[Oh uh you can speed it up by using Mac OSX Java's built into the OS!]
How about, because he, unlike others, does not seem to have failed 5th grade reading comprehension? He's never heard of a good programmer _who uses Jave_ outside of Sun.
Try Corewar @ www.koth.org - rec.games.corewar
Just because it's the most popular does not make it the best. I mean, look at MSWindows...
Besides, the Original bittorrent client was written in Python, not Java. There's a reason for that. Maybe the programmer would not have done it at all in Java, and never created BitTorrent.
Python is a great prototyping language, and "great hackers" like it because it hardly gets in the way of a quick hack.
If I had an idea on the way home from work, and wanted to hammer it out in 15 minutes on the olde pc "just to see", I certainly would not use java.
"Piter, too, is dead."
All of the BSDs use GCC as the default compiler.
Obviously. But what does it link against???
Is "Hello World" contamination-free if you compile it with GCC on a FreeBSD platform?
It's a serious question; I'd appreciate serious answers.
Excuse me. I thought we were supposed to be
engineers. Cool. What kind of lame excuse is
that? We pick up the hot horse pucky and run with
it... Right?
java can leak memory just like any other language
Yeah, but you have to work a *lot* harder at it.
but java might if you leave it lying around in some persistent collection.
Huh? What are these mysterious "persistent collections" you speak of? Yeah, if you hold a reference to a collection and leave an object in it, it won't get garbage collected. Duh. Don't hold onto the reference. And if you actually manage to create circular references, well, that's your own fault... the JVM can only do so much.
sure, you might not have header files, instead you have interfaces which allow different classes to depend on each other.
I'm not sure what your point is, here (especially the reference to interfaces). In C/C++, you need a source file as well as a header file, and need to track both. The advantage of Java is that the two concepts are merged, so you don't have these nasty dependencies to deal with.
java does alleviate the problem of pointers, but it has plenty of other problems it introduces.
Such as?
the stuff you mention isn't "crap," it's just that java masquerades most of those things
a) yes, it is "crap". ie, it's a bunch of crap that, in C or C++, the programmer has to manage (e.g., memory and header files). How, exactly, does java "masquerade" these things?
as the size of the project grows, java has as many problems as other programming languages.
Bullshit. At the company I'm working at, we're creeping up over the half million line mark, with half of that in java and half of that in C, and I can say unequivocally that C is a *much* larger pain in the ass to manage, build, and maintain. But, since you seem so sure of yourself, please, explain to me these mysterious scaling problems that Java has.
It's not a memory leak unless you forget where your "arena" is. It's just a poor choice of allocation/deletion strategy for that app. If you're truly running in steady state, then the traditional malloc/free (or new/delete) approach should work fine instead. Either that, or you shouldn't be allocating much any more.
If you do have discrete processing steps (e.g. sending off a bunch of queries, constructing a web page, whatever) that are largely self-contained, though, the arena strategy can work well. I do agree that it's best for batch-oriented tasks.
--JoeProgram Intellivision!
Are you flipping crazy (or trolling)?! Go to freshmeat.net, browse to the projects by programming language, and look at the number of projects writting in java (currently 3257, about what C++ is at). Are you telling me and everyone else that every one of those projects are both non-free and solely written for "Java monkeys"? What a total load (as are your "statisics").
But you have to agree that Azerus is probably the best written client out there..
I do a lot of prototyping work in Java - that's because I am fluent in Java.... and I can do it just as quickly as most people who do it in Python!
"(Any helpful links to a good C++ API (not GUI toolkits) which is both POSIX and Windows might make me use that some more.)"
Isn't the WinNT codebase supposed to be able to run POSIX apps?
In every computer language, after all the pretty abstraction is over, at some point, bytes need to be copied to/from hardware. The problem with Java is, they try and hide that ugliness. That's not a bad thing, and it doesn't doom other languages that try it (Perl, VB, etc.)
The killer is, Java tries to hide this ugliness *regardless of platform*. And in the process, it bleaches out the goodness of the target system and inevitably screws up something. Hence, you have to go through hoops (albeit easy ones) just to do a 'right click'. In Windows, if you have a menu pulled down, you can click the title bar and it closes the menu for you. Not so with Java (at least with Swing when I was last programming in it).
So, for any app that has to interface with non-universal software or hardware, Java creates pain. You have to write a wrapper to access the registry. You have to fight UI flaws and performance. Trying to make your server app launch as a service kind of works, but the implementation has holes you can never plug, and so on.
So, yes, Java creates this beautiful, perfect OO world that's a joy to program in. But it does so at the expense of dealing with the reality of the needs and capabilities of the platform.
Does it hurt to hear them lying? Was this the only world you had?
Yep. The Cray C compiler is this huge, slow, stinking mass of algorithms designed to figure out what high-level process (sorting, matrix multiplication, etc.) you're trying to write in medium-level C code, and then it drops in fine-tuned assembler code and makes a few substitutions, and, voila, your app runs on a multiprocessor supercomputer.
There's no reason a very well-engineered language aimed at solving the majority of common computer problems very well couldn't have a syntax where the compiler always knew what the programmer was trying to do, and could simply spit out bytecode corresponding to the different abstract steps that the program goes through; the interpreter would execute highly-optimized native routines, and this setup would easily outperform standard compilers for most tasks.
Of course, designing these types of programming systems is very difficult, indeed... but, to some extent, it *has* been done, there just aren't very many options yet...
--TheOrangeSquid Is it any wonder things seem so awry? We swim in a sea of confusion and don't have to think to survive
Besides, success is its own argument. If you can't understand why Java is so big these days, maybe that's your fault, and not the world's.
How true!
And the same goes for Budweiser, McDonalds, the Ford Escort, and reality TV, as well. Who cares if they are good or anything; they are popular.
Microsoft is to software what Budweiser is to beer.
JRE 1.4.2_05 offline multi-language install is half that size. An online single-language install will require about 7.6MB of download.
It sounds like maybe you have the JDK.
Education is a better safeguard of liberty than a standing army.
Edward Everett (1794 - 1865)
Use e.g. monads or "single-use" values.
Single-use values are used to represent the parts of the outside world that can change -- when, say, inserting a record into the database, you pass a value representing the database to the "insert" function, and it returns a value representing the modified database, and invalidating the previous "database" value.
Arguably the invalidation of the old value is still a side-effect, though, and it's still somewhat awkward to use.
Monads approach things the other way around, permitting you to set up purely functional "pipelines" through which state will be passed at runtime (but the state-passing need never be explicitly exposed, and in the pure sense cannot be).
Monads work very well, and maintain purity (without having to pass extra arguments around everywhere), but they're very, very mind-bending to think about until you get accustomed to them.
There are also other monad-like approaches (e.g. "arrows") which are possibly better, but this is an area that's still being actively researched.
So, it's possible today, but really it's an issue computer scientists have only recently started to experiment with in earnest; I expect we will have even better approaches for managing state in functional programs in the next few decades.
DNA just wants to be free...
..is that we'd just appreciate the good engineering done by others and build on it rather than prattle on like little old ladies. Maybe I'll die of old age before this happens but I have dreams...
Yes, Java (the idea) was wondrous. But not new. The UCSD p-system is the root of most of these ideas. Sigh. C# is prettier (and I ought to contribute to mono (I feel guilty)). Don't we all. I have to eat, my brethren and so do you. The catch is that we don't want to sell our souls in a faustian bargain. I just looked at the previous sentence and realized I was threatening to be a cannibal (ouch).
oh well. Maybe I have the appropriate skills in dyslexia to become a U.S. president...
I think there are a few invalid points:
- "Java has been considered slow"
Perl and Python are also not considered fast, but
those who use them consider themselves cool.
No, the speed is not such a big factor.
- "Swing disasters continue"
Yes, but do you see Perl and Python programers
write GUI apps? Ruby? Scheme?
- Java did not have a good IDE
I've never used an IDE to write Perl nor Python.
You don't need an IDE for them, most of the
time. That is precisely one of the factors that
makes them suitable for hackers. Hackers like
it lean and mean, and not big, heavy, and
complex, and that is exactly what IDEs tend to
be like.
Other than that, there are good points. Anything for the masses is not cool, and this is not limited to programming. Everything around us works this way. Any PL that requires you to write a pile of code before you see the effect is uncool. Perl, Python and Ruby all allow you to get something working very quickly.
Simpy
Yup, nothing like having your Windows users install and configure Cygwin in order to use your Java app....
The society for a thought-free internet welcomes you.
1. A hacker is a good person; curious, but harmless. :-)=====
2. A cracker is a bad person; curious, and dangerous.
3. Curiousity means you want to know how the damn thing works, all the way down to the hardware.
4. To get to the hardware (registers, port I/O addresses, etc) you need a programming language with instrinsic low level capabilities.
5 The most popular languages with a compiler on almost every piece of hardware is: "C", and "Forth". Of course "Forth" is usually used to bring up new hardware as a prom monitor, so it really is for the geeky (yeah, ok, me)
COBOL - Caffeine Oriented Business Object Language -> JAVA
I use "C" for fun (24 years now), I use Java for a paycheck.
I also specifically loved the good type checking and the like. I want that from my languages.
What you gain in stability you lose in flexibility.
Python/Perl have very smart primitive types (basically: string, array, hash [not correct terminology for either language - but a good approximation]) that can be retyped depending on the context in which they are used. For example, a string can be used in a numerical context for calculations without having to waste space translating the string to a number, then assigning it to a numerical type. This typecasting is automatic - something the programmer doesn't have to think about.
However, now the programmer is responsible for his own data integrity. In practice this is far less time consuming than in traditional 3GLs. Furthermore, for those 'one-off' administrative/glue type apps - you can ignore it entirely if the manipulation of the data is well defined (such as in filtering) - you don't have that luxury in Java, where you must define your variables up front - a fixed overhead cost to every application.
I don't grok functional-programming...
By functional-programming, I assume you mean structured programming? I think it is safe to say that every programming language, save Schema / Lisp, can be used in a structured (non-object oriented) manner. I can't imagine understanding OO without having first understood the basics of structured programming. Having the reverse be true boggles the mind...considering that structured programming is simpler than OO in most cases.
Lodragan Draoidh
The more you explain it, the more I don't understand it. - Mark Twain
As JIT technology matures for these languages (like psycho has for Python), statements like the above become less and less true.
The same advances also make java faster, but this is beside the point since I'm not actually knocking these languages for being slow -- I personally don't care that much about CPU speed so much as speed of development and clarity and reusability. In fact, I love perl, python, and ruby and I'm not a language snob. I was just pointing out hypocracy in others who throw mud at java and then use a slower language. In fact, I've used both jython and jruby and groovy for various tasks at work.
What are you doing with pointers that you have to spend any time at all debugging them?
What are you doing with pointers that you don't have to spend any time at all debugging them?
The three common failure modes are improperly initializing a pointer, bogus pointer arithmetic, and mistakenly assigning one pointer to another when the referenced structures are different. These situations usually don't appear to runtime and then often produce non-repeatable behavior.
If object-pooling is a prerequisite for a good program, then the runtime system isn't doing it's job. It is a pain to perform object pooling and you have to design your objects differently if you want to allow them to be pooled.
It would probably be a better idea to attach attributes to classes to provide hints about how they're going to be used. That way you don't have to actually change the way your program works to reap the benefits of pooled objects. Make the VM do it for you.
A lot of the time, a generational garbage collector can handle the deallocation of many short lived objects efficiently. In the canonical copying collector implementation (a generational GC is a copying collector) allocation is extremely cheap too (just incrementing a global variable) and has a good chance of being much faster than maintaining a weakly-referenced free list object pool.
Because we all secretly wish we were still programming in COBOL.
The society for a thought-free internet welcomes you.
It's not just slow, it's Java slow.
Don't Crease the Weasel!
I think Java is most seen as uncool because it's simple (or atleast the complexity is pushed into the APIs) and it's used mostly for enterprise development that traditionally COBOL was used for, and not for desktop apps and systems programming (not that you can't do these in Java).
It does have some redeeming features tho (it certaining is a better COBOL than COBOL!)
1) Java has absolutely the best programming tools out there
There is nothing out there that touches the Java IDEs such as Eclipse and Intellij. Some of the advanced features they provide like intelligent code completion and some of the refactoring support are impossible to do with weakly typed languages such as Perl or Python, and very difficult to do with natively compiled languages such as C/C++.
2) Java seems to becoming popular for a lot of OO and software engineering research. A lot of the originator of ideas such as design patterns (Erick gamma), refactoring (Martin fowler), XP and test-driven development (Kent Beck, Ward cunningham) are Java people.
3) You can do some amazing hacks in Java, using features reflection, dynamic class loading and byte code engineering, etc.
C++ looks like it's more powerful than Java because it supports templates, operator overloading etc, but Java also has some features that let you do some quite advanced things. For example look at the Jakarta Byte code engine library (BCEL) and look how it has been used in AspectJ and Jython. For example in Jython you can run an embedded Python script in your application that can seemlessly call any Java code, catch Java exceptions and so forth - i can't think of any language designed for embedded scripting that is this convenient.
4) Java has a huge open-source development community
The average Linux desktop user probably doesn't realise this, but there is absolutely piles of open-source Java development going on. A lot of this is on libraries useful for server-side enterprise deployment, web frameworks, workflow engines, object-persistence layers etc. but there is no shortage of projects out there.
On the whole i think the Java world is more interesting that people give it credit for.
If you don't find the snipped useful, just fucking ignore it. Shithead.
std::disclaimer<std::legalese> sig=new std::disclaimer; sig->dump(); delete sig;
Very slow. I have done some programming in Java, and one thing I notice is that it does even the simplest processing, addition, subtraction, loops, recursiveness--all slower than C++. Much slower. Unless I add hardware acceleration, it takes 1/5 of a second to clear the graphics window on a fast computer. It also has annoying limits on things, like how deep a recursion can go. Even when compiled specifically for x86 (there's some java mod to do that, forgot its name though), it is still much slower. And the most annoying thing IMO is that Java doesn't give me options on how to do things--it makes me do things EXACTLY how Java wants me to do them, whether I like it or not. IMO, that is the worst part of Java.
Yeah, but YOU didn't write bittorent. A python programmer did.
You could write an AI expert system in javascript if you wanted to. I am not saying one language is better than another for this task or that.
All I am saying is that for people who are "hackers", Java is not as "attractive" as python.
This attraction is the "coolness" factor.
I agree that to build an enterprise-wide web-based data-back-end high availability, fast and robust multi-thousand user application, Java is the better tool.
But "hackers" don't want to develop billing software and reporting engine for banking or healthcare. They want to make things like bittorent, for fun.
And it's the "fun" that makes it "cool".
"Piter, too, is dead."
I did not say Python was clearly better than Java. Python in general produces more bug-free code. There is more to a language than producing bug-free code.
In my projects, I tend to use Python or Java depending on the problem at hand.
Depending on your definition of 'open source' then Java is or is not open source. If your definition of open source is that of the source being available, then the source for the J2SE (Java 2 Platform, Standard Edition) source code is available under the Sun Community Source License.
Jumpstart the tartan drive.
Well, I'll address some of this
I don't like the naming convention of firstSecondThird. first_second_third is simply more readable
That's personal preference. I personally hate moving my finger so far out of the letters to get to the underscore. Also, nothing stops you from naming things in java any old way you like.
I do like . notation and I'm happy it's spread to every other language.
sure, sure.
I don't like try, catch. It's important to roll up errors but try, catch just turns into a mess usually. Perl's "or die()" way of doing things isn't great but I do like it better.
The propogation of try...catch throughout a system is a design mistake, not the fault of the language. People that treat exceptions like non-exception error handling are the culprit here.
I don't like strongly typed languages. Dealing with an overloaded object as a basic type that automatically does what you would do normally, usually requiring less variable names and code is a win.
This statement makes no sense. Perhaps the concept of polymorphism is unheard of in your world? Not sure. The thing is, that whole second sentence is one of the greatest features of java, and all other object oriented languages. As a matter of fact, it's part of the definition.
There's too much overhead in Java.
True enough
I believe that the only sufficient documentation for code is code.
Here, you simply have no idea what you're talking about.
Comments can be wrong and never telly you precicely what is happening so a good programmer never relies on them, you have to read the code to figure out what is going on.
And code can be obtuse and completely unreadable, forcing you to spend hours deciphering what someone tried to write in a blur of speed.
Things should be represented consisely so they can be read and understood quickly.
Properly designed software ends up like this, with low level plumbing going on behind high level code that is concise, clear, and hopefully descriptive, if the names are chosen correctly. You can make an ugly mess out of any language. As a perl devotee you cannot disagree.
What it comes down to is you are complaining about poor java code, not java itself.
Slashdot - where whining about luck is the new way to make the world you want.
Whoa, this guy doesn't write real software. He's a scripter, like a high-end VB guy.
I'd count "choosing technology which does not require paying attention to useless details" as a more valuable skill and one that increases productivity more.
Since errors happen when there are more details than capacity to attend to them, we should strive to both eliminate details and increase attention capacity. The details in question here that are demanding attention are useless waste that should be eliminated.
If you love paying attention to details for its own sake, take up chess.
It's because of the mean skill of Java programmers. "Lisp as an Alternative to Java"
Bringing objects to the masses, Java is the COBOL of object orientation. Java may be practical, but it's un-hip & un-fun.
I agree with you mostly but: 5) Have to set things to NULL or the GC doesn't work as well. You're joking right? Hint: NULL is not even a Java term, null is. GC works 100% as designed. Or maybe you mean within one big fat method? I have seen the Java world polluted with untrained "programmers" but, that's the nature of any technology. First the good people do it and then all the slackers show up. My wife was a nurse and same thing. Now you're probably getting your healthcare from somebody with 2 years or less of education. They basically have replaced the RN's with CNA's which is bad cause the RN's were the hands of the doctor as it was! Same for coding. The times when your buddy next to you knew exactly what he was doing are well gone. Now it's a retirement field. Do the cool stuff at home.
Not really.
C is not constrained to writing operating systems. C can be used to write just about anything.
Java, however, cannot be compiled to native CPU code. Given that it could be, your control over the RAM of that system would be clumsy at best. Also, device drivers and such, would all be impossible to write.
C, however, could be used to write a web application.
Thanks!
The majority of his article did not revolve around advocating *nix over Windows
Correct. I gave one clear, obvious example of a questionable conclusion he reached by drawing all of his "great hackers" from a very small and non-representative sample of the working programmers on Earth. This is why I prefaced the example with the phrase, "for example". Because it was an example. See?
Perhaps the phrase "platform advocacy" was ill-chosen; perhaps I should have said "platform and/or language and/or tool and/or whatever advocacy". Hell, I could've gone on for a whole paragraph clarifying a point which was painfully clear to anybody who'd read the essay.
You probably didn't notice that another of his points had to do with saying that cool programmers don't like Java. That's understandable. After all, how could could you possibly have noticed a little thing like that, in the middle of 1000+ Slashdot posts about precisely that aspect of his essay? Whether it caught your attention or not, it is, once again, platform and/or tool and/or language and/or blah blah blah advocacy.
Bottom line: He says that smart people all like the same stuff he does, and anybody who makes different choices is an idiot, and that's an important part of what he's saying. This is often called "platform advocacy". It's more often called "bullshit", but that term was too general for my purposes. There's a wealth of bullshit in Graham's essay, and I wanted to be clear about which particular steaming pile I was asking the reader to sniff.
"Offtopic, Inflammatory, Inappropriate, Illegal, or Offensive" -- hey, that's me!
crash everywhere. Although ourtools is one fast, solid little jar:-)
It gets worse. If you don't fine-tune your runtime's heap size for each app, then you'll discover just how slow GC can be.
Setting the runtime heap size to the size of your machine's RAM might be a natural thing to do, but in a good many cases it's completely wrong.
No, I think he means functional programming. You know, that Lisp / Scheme ( / ML / Haskell / APL / Joy / ... ) stuff that can't be used in a structured manner. Non-imperative programming.
It's kind of an interesting field.
Please, do we have to hear this comment every time Java comes up? It was cool to say that in the 1990's, but it's a little out of fashion now.
Yes, perhaps because it is true. Or was in the 90's anyways when processors were a wee bit slower. I had a 700mhz Athlon and was taking some java classes years ago and it was horrendously slow even when making / using the simplest programs.
That said, it's better now, but seeing as it was all but useless for anything except perhaps for teaching oop 5 years ago, it might be a while before the stigma dissapears.
1q2w3e4r5t6y7u8i9o0pqawsedrftgthyjukilo;p'azsxdcf
Oh, sure it's got an explicit full-on syntax, but I'm comfortable with that. What I was most impressed with was there was a vast amount of standard data types and APIs available to accomplish a very huge amount of stuff. Looking at C++ and the like, the APIs are anything but cross-platform. (Any helpful links to a good C++ API (not GUI toolkits) which is both POSIX and Windows might make me use that some more.)
:-)
Try Qt. In its current version (v3.x), the GUI and non-GUI APIs are somewhat merged, but v4 (currently in progress, due out soon) is supposed to have full separation between the two. Even now, it still works. It's write-once, compile-anywhere (Linux, Windows, Mac), GPLed if you're writing GPLed code for Linux or Mac, and has an OO library and design that is simply gorgeous. It's like C++ done by people who worship Java but hate Swing.
KDE, Opera, and various others use Qt, so you HAVE seen it in action.
For the type of code I was writing at the time (oddly enough, server side stuff behind a web front-end, no GUI) I found I could always find a standard routine to do what in the past I've had to implement from scratch.
If you're doing web apps, definitely look at PHP. I use it for all of my web work, and love it. The new PHP5 has a reworked object model that is very Java-ish, but also has a lot of other features that make life simpler. I've also started using their Smarty template engine, which is a godsend (a web front end IS a GUI, just a different kind of GUI), and there's a huge online archive of code you can use in the PEAR archive.
--GrouchoMarx
Card-carrying member of the EFF, FSF, and ACLU. Are you?
I still make plenty of errors -- plenty of 'em -- but these days they're overwhelmingly logic errors, for which I have nothing to blame but my own stupidity.
That said, I much prefer dynamic scripting languages like Ruby. Even though I don't always have the luxury of using them, I like to think they've made my C++ just a little better.
"I call a baby goat a 'goatse.'" -- my non-Internet-savvy 6-year-old stepdaughter
"MS hasn't included Basic, Visual or otherwise, with its operating systems since,I dunno, DOS 3.3?"
Sure it has: DOS, through 6.22, included QBasic; Any version of Windows running MSIE (<6-7 years old) includes a copy of both VBScript and JScript. In later versions of Windows with WSH, it's possible to use either of these languages to usefully automate things. The only thing that's really changed is the relative importance of the programming tools in the overall system: When your system's editor is edlin and the only end user application is command.com, gwbasic [1] is a lot more important than it is in, say, Windows XP.
1] I remember Compaq using the BASIC interpreter to write sales demo software for their computers. They even had a little game they wrote, "Compaq Portable", in which the primary goal was to collect as many portable computers you could in 60-seconds.
By functional programming I believe he means functional programming .
I have never seen so much utter nonesense that what I'm seeing posted in this forum today and my karma has been 5 since 1999. I code more in C now than I ever did in Java but clearly you people have no clue what makes a good programming language or how to program. Java is a great programming language. Most of these posts are downright incorrect. And why the opinionated ones get modded Insightful is beyond me.
I'm not cool?
Well, if a language is truly WORE it should be impossible to write a non-portable program by definition, no matter how bad the developer is.
I responded to your grandparent post as well, but here we go correcting you again. Check up on things first :-) You said java can't compile to native code, and here it is The GNU Compiler for Java. Right on its front page it says
"GCJ is a portable, optimizing, ahead-of-time compiler for the Java Programming Language. It can compile:
* Java source code directly to native machine code,
* Java source code to Java bytecode (class files),
* and Java bytecode to native machine code."
Just give up hating java, it is truly an amazing language.
Regards,
Steve
No it wasn't. Java was designed for one thing: to make money for Sun Microsystems. Everything else is secondary.
Yes, it's a good language. Not particularly innovative, but it has a nice clean design. It started out with a good-sized standard library, which has now become so huge as to be unlearnable. 8 points out of 10.
But it's also the only programming language in CS history to come with a corporately-chosen marketing slogan ("write once, run [never the same way on any two platforms] everywhere"). That's a bad bad sign, and you seem to have fallen for the hype. You're smarter than that.
No, it's not all hype. Yes, it's a fine language. No, it wasn't designed to be easy to learn.
You cannot apply a technological solution to a sociological problem. (Edwards' Law)
Seriously though, not having to declare variables, that saves time. Getting automatic dereferencing in for loops saves time. Being able to do polymorphism without subclassing, that makes hacking using preexisting classes really quick. But the biggest win for Python is that it's list processing is second only to Lisp. For all it's container classes, you'll never be able to juggle quantities of data quite as easily or a flexibly in Java as you can in Python.
My notebook backpack is one I got at the first SUN JavaONE conference. It starts more conversations than I care to admit to because people don't know what JAVA actually is and confuse it with the 'end all beat all' way to build apps. Hell, in previous experiences, JAVA was how the project started, but was abandon due to the fact that it was 'TOO BIG' a solution to a complex program requirement. CGI/XML/JSP worked better and faster to develop.
You keep going until you die..."Me".
If I need to bang out a script I use bash. If I need to write a simple cgi I use perl. If I am writing a full program then it is going to be writting in some variation of C (C,C++,Objective-C,etc). Java is OK for stuff on web pages but for that stuff I would prefer Macromedia flash.
Flame me if you want but I don't consider Java a real language. Esp since MS corupted it.
Nick Powers
Encryption: I may not agree with what you say, but I will defend your right to encrypt it...
Possibly less so, since a great deal of the bounds checking is done at compile time.
A good friend wanted to write a CLI for a java app, but couldn't use his tried and true architecture because java won't allow jump tables and trampolining. That is to say the *compiler* won't let you use them, he wrote the CLI in Python, compiled it with Jython and now the EJB is happily running the code.
You can get around a lot of the Java security by using hand assembled byte-code.
09F911029D74E35BD84156C5635688C0
Jesus loves you, I think you suck
Sorry, that's a bug, not a feature. I know this is a hopelessly unfashionable attitude, but all data conversions need to be explicit. The language should make this as terse as appropriate, but no terser... but I don't *ever* want the language to do anything under the hood without my explicit approval.
Furthermore, for those 'one-off' administrative/glue type apps - you can ignore it entirely if the manipulation of the data is well defined
Sorry, I don't believe in the existence of such code. If it's worth doing, it's worth doing with some confidence of reliability.
OK, you lost me when you said that Neither Perl nor C move from platform to platform with the same ease Java allows. I disagree:
1. If we restrict ourselves to Linux, Windows, Mac, then there are GUI toolkits for both Perl and C which are cross platform (for C it's a recompile for each platform). Unless you program in the Metal/Java Look and Feel, Java programs tend to require a bit of tweaking on each platform (and Metal looks like ass).
2. If we do not restrict ourselves to "major" platforms, particularly if we are willing to scrap the GUI, then C becomes the most portable language. Ever programmed in Java on a PA RISC system? Probably not, because nobody has made a JVM for it (although this is dated knowledge).
The only place where Java wins big is in the emerging embedded market, where some companies are making their devices J2ME compatible and not providing a C interface. This market is growing and will likely be more important in the future (it is important to some people now).
Java's "best" is garbage collection, SWT, and Apache. Garbage collection is cool because, as the grandparent said, B coders can't screw up. SWT almost acheives all of the cross platform look and feel objective, at the expense of manual resource management (which is sort of odd in Java). Apache (and IBM) provides some of the most useful libraries and frameworks for developing enterprise applications.
Java's "worst" is installation. I used to think that applets and web start applications were kind of cool, until I noticed that everyone had an old JDK installed on their machine and I wanted to use the latest. If I program an application in Flash, I can redirect the user's browser to require a single click to download the latest player. Users seem to be Ok with this when it is required. For Java, the user is presented with three different things they are supposed to read and click through. Updating Java intimidates some users, just because of the way Sun has tailored the whole experience. Thank god apple updates their JDK through the system updater.
OK, InstallShield almost completely mitigates this problem, but it is still fucked up that Sun hasn't done anything about it.
thanks for reading my long-ass post
you're welcome, thanks for posting it
However, I think you miss a few important concepts in your post.
1) Not all "A coders" are hackers.
- I've worked with the elite programmers that do believe that requirements and documentation are good and that a process produces better results. It seems that these are usually the elite and experienced, but not always.
2) Not all hackers are "A coders".
- "B coders" are hackers too. Seen it too many times. Just like anything else, there are more "B coders" and "C coders" that are hackers than there are "A coders". It is just a fact of life, that there is always an elite FEW, but and abudance of mediocrity. i.e., just because you are a hacker, doesn't mean you're good.
3) Managers are people too.
- There are many "B managers" and an elite few "A managers". And usually, an "A manager" is worth a team of "A coders" to a company.
4) Teams are usually a cross section of the population.
- Rarely are there teams full of code monkeys, or full of "A coders". Here is where a great manager is important. An "A manager" will allow enough room for each person to do what they need to, but ensure that each is able to work with the other. I've been lucky enough to have "A managers", and they make a world of difference to individuals and to projects.
5) Programming languages are just tools.
- Use the best tool for the job. Saying you choose a language based on your ability to do "neat hacks" is idiocracy. If I see someone putting nails into a wall with a screw driver, I think - "Damn, that guy is good with a screw driver", and "what a friggen' idiot".
Reading your post it is obvious that you are either an elitist with a lot of bad experiences, or someone with no experience. Either way, I hope your next manager is an "A manager", you really need some help.
I am living proof of the Peter Principle
exceptions are for pussies. Return codes should be enough, and as a programmer I can decided to ignore or deal with a return code. Exceptions are nothing more then return code that force you to deal with them. How many times have you seen a java app bomb becouse an unhanled 'null pointer exception' the best part is if you talk to a professor Java doesnt have pointers, it only has 'refernces'. Its a crappy language made by non programmer quasi-intellectuals about how they 'think' programmers should work. If people dont understand memory manamgment the solution is not to hide memory manamgent in the language but instead educate the programmers. Lowering the bar just gets us shitloads of shit java applets.
There's nothing "so-called" benefits of static typing. Mr. Eckel seems to have the attitude that strong testing is more important that strong typing, and thus the former more than makes up for the lack of the latter... but this is like saying that if a car has airbags, it doesn't need brakes, especially since it will make the driver that much more cautious.
Strong testing is great. I'm all in favor of it. But give me strong typing too... to borrow a phrase from a source I can't remember, proper use of strong typing will allow me to eliminate a huge subclass of errors at compiletime rather than runtime. I'd be foolish to ignore such a tool.
No, I mean functional programming . Meaning all of that lambda calculus crap and the entire familiy of languages like Lisp and Scheme. Specifically, the exact opposite of what you think I meant.
Structured programming and OO I get. I've been writing code since the mid-late '80s. I learned on procedural languages. OO in something like Java is fairly intuitive because the language form is still, at it's core, procedural in flow.
However some of the bits required to perform functional programming I never successfully wrapped my craw around since, to me, thinking of everything as a mathematical function does not correlate to the way I conceptualize stuff and I never got the knack for it.
So, no, I did not mean structured programming. I do that every day of the week and have for a long time.
Lost at C:>. Found at C.
Not off-topic, IBM has primarily used Java to power the aging OS/2 platform. If you were running OS/2, you'd be running a whole lot of Java Apps.
Of course, don't let a little bit of history get in the way of your -1, offtopic. After all, Windows XP is extremely innovative, Microsoft worked hard to get their MS-DOS monopoly, and Linux was written by AT&T, won by Berkley in a lawsuit and stolen by Linus Torvalds, only so he could be sued by SCO, right?
It's been a long time.
1. C programmers can't be as reckless as they would like to be.
2. C, C++ programmers would have to learn something new to use Java.
3. VB programmers find Java more complicated then VB and more demanding of their programming skills
4. OSS/*nix types do not like it because the OSS community did not make it.
5. OSS/*nix types do not like Java because they can't feel like they have made it more their own as sun does not allow every freedom in altering and redistributing the code.
Plenty of safe, clean language are cool: OCAML, Python, Scheme, etc.
What makes Java uncool is the fact that it is and remains a proprietary language. Also, it is uncool because both the language and the libraries are full of avoidable design flaws; Java's roots as a failed project for a set-top box programming language sadly still show to this day.
But foremost, what makes Java uncool is that it takes forever to get anything done in it: a language does not have to be cumbersome in order to be safe, and forcing programmers to write lots of LOC to get the simplest task accomplished does not make the resulting code more readable.
But whether Java is "cool" doesn't matter as much; what matters is that these problems with Java also get in the way of using Java for real work.
Don't forget Groovy
evil is as evil does
On the other hand, in terms of speed of program development, Python > Java > C/C++. That may well be more imporant. Especially when you are talking a 20x difference is productivity between C++ and Python, which is what I estimate mine to be having used C++ for years, and having since moved to Python.
But you were talking Java. Well, Java fit's in between those two extremes. It's more suited to production code than Python and it's more suited to prototyping than C/C++. It's a good fit for a lot of jobs.
Sun wants to have the best of both worlds; hackers working on their stuff and yet keeping their control over it. When Java was released, Sun was very bad in working with the community on Java; it was Sun's way or it wasn't done. This lead to many hackers not wasting their time on it, and opened the door to Microsoft to play their games on Java.
Also, because Sun saw Java as a revenue product, marketing guys will want to sex it up every year. Java, Java Beans, Serverlets, and more. Versions that don't work with other versions.
Add to this it's history of preformance and lack of opensource support (there is the Apache Tomcat project, but take lots of care if you are going to build a deployment system with it.. and you would think sun would have addressed the java install issues for firefox/mozilla themselves). I really think now it will be a case of too little to late. Python is up and coming, and I think Python appeals more to a java programmer than a perl / php guy. That is, once you learn to love the bomb and stop usinging braces and semicolons =p
I use Java myself, and do everthing from PDA applications to web apps with, also I frequently compile Java into native code for various platforms. I think the stygma started in the dot com era when anyone who could get "Hello World" to compile considered themselves a Java programmer, and thus a programmer in general. This was further compounded by the advent of Java script, managers and recuiters seem to frequently confuse these two, and even further confusion results now that Sun considers Java to be a 'brand' as opposed to a 'platform'. Seems like most of the 'Hello World' programmers LA majors, H1-B's etc., have now been pushed out of the industry. I use Java because it allows me to most effectivley and efficiently deliver applications to meet my client needs, granted its its the choice of hackers, but I don't hack, I write apps for my clients, and I want to deliver the best product for their investment. M
I write Java code for a living. It makes me money. I enjoy it. It's the best tool for the kind of code I write.
I could really give a flying fuck what anyone else thinks.
reech bee-yond ur clip-0n
To write a Java app correctly?
emt 377 emt 4
Good programmers don't select languages because they're "cool!"
And this epitomizes what is wrong with Java. It's a technology that accompanies a marketing campaign. Why? Because for the most part, unlike other computer languages, Java doesn't address a specific niche or application area in any superior way. Therefore there is no substantive need for Java which explains why it has to be heavily marketed to be "cool" so people will use it.
Having been programming for more than 20 years now, I've noticed a dramatic increase in misguided questions newer techs ask me, specifically, "What language should I program in?" as if there is one universal language that will do everything. I've always found this annoying. I'm asked, "Should I learn Perl or PHP?" as if it's merely a question of picking a single language to do everything. While that may be possible, it doesn't do justice to the application if you try to hack a less-suitable language to address a scenario where another choice would be superior.
Java has been dead for a long time. More marketing isn't going to revive it. No computer language will last if it isn't OBVIOUS to developers that it is the best choice for an application.
The bottom line is that C/C++ is more portable than Java, despite the myth of Java being marketed as more portable. Java has better garbage collection and string handling and some higher-level abilities, but none of those features couldn't be plugged into C/C++ with a few libraries. Most Java applications are interpreted or p-code and run hundreds of times slower than lower-level counterparts.
A good example is Puzzle Pirates. A pretty nifty online game written in Java. Unfortunately, the thing is so goddam slow it really detracts from the experience. This application and the company is suffering because they chose an inferior technology as the base of their service.
Java has considerably fewer surprises: on this one he might have a point. I might say "Java has fewer orthogonal features" instead. For instance, there's little ability to do metaprogramming in Java (unless you use AspectJ). There's just lots of interesting things you can't do -- and interesting things can also be hard to understand or cause surprises. Java's compromise is arguably valid, though not very exciting.
Java has been considered slow: obviously he doesn't understand where Graham is coming from. Many interesting languages are slower than Java, including many of the languages that Graham suggests (Perl, Python, Scheme).
Swing disasters continue: again, he doesn't understand Graham. To address his criticism of Java, you must ask "is Swing fun to program" not "are Swing apps fun to use".
Java is strongly typed: well, sure. ML is a statically typed cool language. And Lisp, Python, and Smalltalk are all strongly typed. (If you don't understand the distinction between strong and static, read this.) The problem is really that Java doesn't trust the programmer, not the specifics of its typing. Though if you trust the programmer, static typing starts seeming a lot less useful. And yes, great hackers don't like languages that don't trust them, for obvious reasons.
Java has a vast library that is available to all Java developers: this is a guy with a Common Lisp background. He certainly has no problem with good libraries, and he never mentions any problem with extensive libraries. Programming in an open field can be fun sometimes, and can help you think about things differently, but libraries are never a detraction (you can always ignore them if you want).
Java did not have a good IDE: I don't think Graham said that great hackers really like Visual Basic, and that's why they don't use Java. I laugh just considering that argument.
Java is popular: if you ever listen to the users of languages like Smalltalk and Lisp, they will bemoan at great length that they are not as popular as they deserve. Though you'd only know this if you ever looked at these communities.
Java is an application programming platform: so are Lisp, Smalltalk, Python, etc. Most of the kinds of languages Graham is talking about are not systems programming languages.
It's nice this guy tried, but he really doesn't understand what Graham is talking about. Which is kind of the point -- to understand Graham's perspective you need to have the intellectual curiosity to do non-work-related projects, using environments that are unfamiliar to you. You need to reflect on those experiences and make judgements about what you like and what you don't like. If you've only used Sun and Microsoft languages, you won't get it. That doesn't mean you can't do good work in Java, but if that's all you do, then you won't be much of a hacker at all.
This slightly reorganized version lets you create a list of directories that you want to behave as we've discussed.
First off, create your conf file in
std::disclaimer<std::legalese> sig=new std::disclaimer; sig->dump(); delete sig;
I'm the coolest. I code with MyEmerald5, use HTXML 4.3.065 and run POSTron as my web server. Never heard of them? You must be from yesterday or something...
Of course, the way I usually deal with the CLASSPATH is make ant deal with the CLASSPATH and then just package everything into a mega-JAR and distribute that.
Not the best solution, granted, but...
You are in a maze of twisty little relative jumps, all alike.
I'm not a coder. I do some scripting for administrative tasks and integration work, but mainly I maintain mass numbers of machines.
My hatred for java started with the bizarre things it used to do to my browsers. The browsers (and jvms) have evolved, now java in web pages is less likely to make my eye twitch.
Since then, however, I've seen java from the backend.
The application servers: I've not seen a single well documented Java application server. Tomcat, for instance, has tons of documentation on how to write and install your code. Nada on how to actually configure and administer the server. Sure, Oreilly has a pretty good book that came out, but that's a recent development. You'd think the guys responsible for as well documented a server as Apache would've done better.
Quality of Code: There are good (perhaps even great) java coders. I've seen one or two. The number of Java coders who suck far out number them. I can't begin to count the number of servers I've logged into that are bogged down to a crawl because some piss poor java application has three or four memory leaks that the developer can't seem to track down. I've seen whole development teams replaced three or four times before a qualified java crew was finally assembled. You can always tell they're qualified because code thats dragging the four way Xeon to it's knees could all of a sudden run on an old 300 Mhz Celeron with an eighth the memory and still have horsepower left over. And don't get me started on how most Java coders don't seem to care about exception handling. GRRRRR!
This is like saying that C can't be fater than the assembly. In theory it's true: whatever assembly is generated by your C compiler could have been written by you by hand. But in practice, you don't write assembly the same way a compiler does and it is much smarted about optimizing it than you are. So we reach a point where good compilers can generate more efficient code than would any actual human would write if they hand-coded in assembly, even though they theoretically could write equivalent code.
Similarly, a good JIT will in practice be faster than running native C code. We haven't reached that point yet, but we will because the JIT and the runtime are free to do things (like reorganizing memory to reduce paging and to put certain things on the same cache line) that your C compiler can't do since it lets you have access to pointers to arbitrary memory (and lets you pass them around and do whatever you want with them), and because your compiler doesn't have the same information at compile time about how you use the program that the JIT and runtime do, since they get to see what happens at runtime.
I'd rather be lucky than good.
Slime for emacs is very good, kind of like Dr. Scheme. But it's hard to compare too closely of course.
I work on a project coding in java.
It's a great language.
I'm not trashing it.
It still would be at best awkward to choose java for certain tasks.
This conversation is getting to be like conversations with Perl programmers who wish to use Perl for everything. I am not trashing java... I just think that you would be better suited to use C++ for some applications.
I know why people like weak typing, I used to be a fan of it myself, and it somehow "feels" easier, it just throws up a lot of errors when used.
This, for the most part, is a fault of the standard library which makes doing simple things much more complicated than it ought to be. But I covered thatYou are not alone. This is not normal. None of this is normal.
Common Lisp and Scheme are very different. If you encountered it in college, it was Scheme. Lisp has no bias for recursion; it is multiparadigm.
That being said, Java has no way of hinting to the compiler "this is going to be constant for a long while now", or "I'm going to run this loop a couple of million times in a bit, you might want to JIT it real good". Without those, the compiler doesn't really have a hope.
You're right, but that's not a problem with one certain method of JIT compiling: HotSpot's. HotSpot profiles the code as it runs, and decides the best way to compile something. It knows how often a test-and-branch will branch, and can arrange the native code accordingly.
There's an additional execution time hit at the beginning, but 1) it compiles faster code; and 2) it doesn't have to compile code that isn't executed.
You also failed to mention that a standard JIT compiler can make processor-specific optimizations that a normal compiler has no hope of making.
Then again, I've seen Java out-paced by many of these languages (most of which compile the program to byte-code at start-up faster than Java loads), which suggests to me that Java is just a poor interpreted language.
Most out-pacing from other interpreted languages is due to operation-specific optimizations that have nothing to do with the fact that either language is interpreted or JIT-compiled. (Or were you suggesting that these other languages are faster in everything?) I can't speak to Python or Perl, but I can give a Java vs. C++ example. Java's collection and string operations are much faster in the general case than the STL's, because of Java's choice of reference semantics and immutable strings. (Ironically - for people who accuse garbage collection of being a performance hog, anyway - it's the garbage collector that makes it possible.)
That some operations in other interpreted languages are faster than the same operation in Java doesn't really surprise me. I'd be much more surprised if any language were better at doing everything.
I got my Linux laptop at System76.
java did promise to fill both embedded hardware and web-app space.
it failed on both counts.
Speak for yourself, idiot. Many programmers thought it was unbelievably lame that a programming language had TV ads. Uncool from day 0.
Aside from redraw, Eclipse is one of the slowest starting applications I've ever seen. It takes over 10 seconds to pull up the main window on a modern machine.
However, it's worth the wait for its refactoring capabilities.
I see job security.
Because none of you have got an eye for the business imperative behind most language decisions: Make your software assets, your hardware assets and your people interchangeable.
Here's how it works. I'm in a mgmt meeting and the SPHB tells me that he thinks it would be reaaaal cool to put the temperature in Cleveland on the "About Us" page so his granddaughter can see how shriveled old gpa's testicles are. So I mention this change to the appropriate product manager and soon enough, resources are queued for that job and it gets passed out to a SNK (snot-nosed kid) for implementation. SNK immediately whines that we need Perl if we're a Java shop, Java if we're a Perl shop or a combination of struts, EJB's, an EJB-.NET bridge and some back-end VisualHappyHappy(TM) if he's had too many Mountain Dews that day.
Like WTF? "The best tool for the job" means crap to me when our software doesn't have to articulate the friggin Space Shuttle. If SNK goes and builds some monstrosity that only he understands, WhoTF am I gonna get to maintain it? If I let the nerds pick their favorite needle-nose pliers for every job, I'd have a whacko menagerie running on six different platforms in one month flat!
Thank you, I will retreat to my cave.
Wow, both emacs and Lisp. That's like being able to change the colour of the rock I'm bashing myself over the head with when I could just put down the rock.
I'll stick with vi and non-Scheme-like languages thank you. =)
Lost at C:>. Found at C.
If you're looking for a GUI IDE, you'll have to go with one of the commercial Common Lisps, or one of the Scheme variants mentioned in other replies. However, lisp-in-a-box will get you hacking pretty fast - it's Common Lisp + emacs + slime (superior lisp mode for emacs) in one easy-to-unroll ball that should Just Work on the platform of your choice.
This link normally works, but common-lisp.net appears to be offline as I type. Google will show you the sites for various platforms
To a Lisp hacker, XML is S-expressions in drag.
I measure 105 milliseconds before main() gets called (1.7 GHz Pentium crippled by Windoze). Actually less, as that figure includes both application startup and shutdown. What do your measurements show? You have measured it before having a problem with it, right?
Is that a showstopper for many of the applications you write?
Don't I? Have you never run across documentation in source code that wasn't updated properly when the code was changed or simply was wrong from the start? Reading only comments is necessarily insufficient for understanding a program. Furthermore, if the program can be written in such a way that it's just as easy to read the code as the comments, it's redundant.
But one of the goals of a language is to make code easy to read. Much of source code's roll is about people telling other people how to get computers to do things and as such, it should work like a natural human language. Some languages are better at this than others. C, for example, is notorious for requiring pages of code for something that in English would be described as "split this line up on spaces and put the first thing in this variable, and the second thing in that one, etc.." One of the measures of the quality of a language is how easy it is to read. Some of that depends on the programmer but a lot of it depends on how the language is structured and what operators it has. Java does OK there but is not exceptional. Python, for example, is much better.
You can make an ugly mess out of any language. As a perl devotee you cannot disagree.
True. Much of perl's bad reputation is that people often port shell scripts to it when the shell language just isn't quite good enough and the resulting mess is completely unmaintainable. This isn't an issue with the language but it does make it look bad. Of course, it's also not just the programmer's faults. Perl has some ugly things in it's language too.
You can't deny that there are things inherently inside the languages that affect readability.
As computers mature and standardize less code will be written from scratch and more will be read and slightly modified. In the future, a language's readability will be even more important to productivity than it is now. As such, it is possibly the most important aspect of language design.
set softtabstop=4 shiftwidth=4 expandtab nocp worlddomination
java is more like a jackhammer than a dental drill. It surely has its places but its not fun to use.
A factor of 5 is too large to discounty by any supposed greater "amount of mental effort" you hypothesize.
Seastead this.
Interesting discussion.
.NET? The structure and goals of .NET look like the best of Java with other stuff thrown in. The point here? It's the marketing dummy.
.NET! And why does that matter? Because without competition the MS machine will assimilate us all!!!
Although this is a site / topic aimed at developers, it seems their are some "big picture" things here being glossed over. IMHO.
For one, someone upstairs said, "different languages for different problems." Hear hear. No one language is great for everything. I can think of three different languages I use for three different problem domains. C for device drivers, perl for system admin functions, (even on Windoze machines), and yes, Java for "big" e-commerce apps.
Java IS an excellent, strongly typed, OO language. When a problem lends itself to a good OO approach, and I'm not required to measure clock ticks for performance, I prefer Java because it makes it easier to do.
On the downside. I've been frustrated in the past with lack of JVM support for various devices. (And too dang busy to write my own!!)
And this brings us to the final "big picture" issue. Have you ever taken a look at Microsoft
We can argue about syntax, tool support, and performance all day. But in the end, one of the key things about Java is, JAVA'S NOT
MS is rapidly advancing to take over everything from the palmtop to the desktop, the set top box, and even your automobile. We need more alternatives that don't wear an MS brand. I would like to see us break out of some of these old, tired issues, and start focusing on what we can do to advance the state-of-the-art in more competitive ways.
Try saying that if you used a 133 up until a year and half ago. On that, JAVA is slow....
Free software is written in C (65%), C++ (25%), and Python and Perl (all but the last 1%).
The latest complete count of a Linux distribution was of RedHat 7.1, http://www.dwheeler.com/sloc/. Shell, Lisp and Assembly all beat out Perl, and Fortran is also above Python, then TCL and then Java. So Java's tenth, with a half percent of code, and there's a lot more variety than you would imply.
Damn right. There are plenty of situations where I would have used Java, if it wasn't for the startup time.
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
Best editor ever! VI was my editor of choice before and still use it in a pinch, but JEdit blows it out of the water.
And if you're wondering, Emacs sucks.
Java is seen as uncool precisely because it protects you from your own mistakes... You're absolutely right about the ego trip, but the idea that C doesn't protect you from you own mistakes is an excuse, not a reason, and a false one at that. C does protect you from your own mistakes and does make programming approachable to the masses--that is why tens of thousands of programmers use C instead of assembly language. (And even assembler provides a layer of ease and safety over raw machine language.)
I don't like Java, but it's just because of personal taste (or, better, general personal taste about who usually programs in Java).
Trashing these prejudices (that I read between the lines of many posts above), it remains one consideration to do.
I think that Java works well for server apps. If you've to build a server backend with a commercial JVM, or a framework, it is a really good choice (though not the only one, obviously).
When it comes to GUI / client side application, using Java is synonim of suicide, imho. You can say Java is fast as C/C++ as much as you want. I simply don't believe it. Moreover, using Java for that isn't the most wise thing to do, when there are much faster and easy pls to go with.
There's another thing to say: I hate Java since it is not an open standard.
Ok, I'm a Free Software advocate, I admit it. Having Java as free software would be the best, that's for sure. But not having it open standard is a lot worse... you cannot do your free (as speech) compiler. You're tied to a company (Sun Microsystems). It's a monopoly driven by a single head... that can change its path -- and Sun has demonstrated many times to be as dangerous as Microsoft for the OpenSource/FreeSoftware community.
Let's only hope that gcj/gij will reach an usable status. Maybe then I could start using Java for everyday use. Until then, I'll go on with C,C++,Python,Perl,Scheme... and so on.
42.
I've used some enterprise apps that run on AIX, HP, Solaris, Windows and DEC Unix.
Try looking at something like Apache Coccoon, you'll be impressed.
Newer Java apps aren't the stupid applets of a few years ago...
Conformity is the jailer of freedom and enemy of growth. -JFK
That is, in a nutshell, my point.
Just as Java developers hate hearing, "Java is too slow" C++ developers hate hearing, "memory managment, lack of garbage collector."
A legitimate complaint about C++ is its [in my opinion] less than exceptional exception mechanism. But then again all industrial strength tools have warts on them right? I think they are also known as 'weaknesses' and more popularly referred to in langauge flames as 'cons'.
BSD is designed. Linux is grown. C++ libs
Foremost, Java is a language for object oriented development, and all the hacks are in OO design and development. A lot of B coders screw up Java by writing it like C. The B coders screw it up even worse when they apply patterns incorrectly.
I'm dealing with both cases. I'm maintaining code that in some places uses lables and other places simple objects are created by builders that create factories that create abstracted objects that have to be cast to the object I want.
I spend all day refactoring, and that's where the neat hacks come in. I clean up the design and shrink the code without losing flexibilty or functionality.
Unfortunately, OOD is hard, and in Java, it's where all the creativity and 31337ness lies. Java coding is incredibly satisfying when you're able to break up a massive switch statement into meaningful classes or correctly apply a design pattern and watch a giant class indented to column 80 dissolve into a few cooperating objects.
When I do that, I understand that the Java community has done something incredible. It's made maintaining code a creative activity. I imagine many developers, especially ones who favor scripting languages, never make it this far along in the process.
One final and related reason that hackers may not like Java is because it requires the ability to communicate. For me, one of the hardest parts of OOD is naming my objects. Whereas in C or perl it's common to keep names at one or two letters, in Java you really have to name parts of your program, or everything becomes a meaningless mass of FactoryAdapterConstructorBuilders. I've found that poor naming leads directly to poor design, and that's just not something many programmers are good at.
ICRTABIRTH (I couldn't read the article but I read the headline). YMMV.
Java is uncool because whenever I load up a program coded in Java, it eats up between 40 and 60mb of memory, whereas a similar program coded in C++ takes up 20mb.
Java is uncool because the C++ program is faster on EVERY platform than Java.
Java is uncool because although it's supposed to be supported equally on all platforms, it STILL isn't, and you'll get oddities that only affect Windows or Mac or *nix, so instead of coding for one platform, you're coding for all three AND writing code to handle exceptions on each. In comparison, C++ could be written for Windows and be ported to Mac without having to worry about the Windows-specific bugs.
I'm not trying to troll, but I avoid Java programs whenever I have the chance, because typical Java programs make Windows itself look quick and lean by comparison.
Doesn't mean I don't use Java... in many cases it's inevitable (I play Go online, and my preferred server only released a Java client)... but if I ever had a choice between Java and C++/ASM/whatever, I'd pick C++/ASM/Whatever instead.. so long as "whatever" is Turing-complete (I've yet to see an infinite loop in Malbolge, so it doesn't count.)
present day... present time... hahahaha...
Sorry, that's a bug, not a feature...
/etc/passwd file has a standard format that any program can read without explicit checks. Why waste time building an application that is going to be bullet proof - when you will only use it once or twice or for a clearly defined purpose?
There are thousands of developers that would disagree with your myopic viewpoint.
If it's worth doing, it's worth doing with some confidence of reliability...
Not every application need be gold plated - and still serve a useful purpose. Data integrity can be ensured in the data prior to reading into the application. For certain system administration tasks, you can make assumptions regarding formatting.
For example, the
This cuts to the core differences of the *nix OS and other less robust OSes - the tool making paradigm versus the monolithic application paradigm. I can get more done in a shorter time using tool building and interprocess communication than I can building stand alone apps. On the one hand you have the best of both worlds - you can build one-off apps, as well as full blown 'proper' applications; on the other hand (your hand) you can only build monolithic apps for everything - which leads you to try to build one app that does everything but nothing well.
Lodragan Draoidh
The more you explain it, the more I don't understand it. - Mark Twain
But then that will means that you abuse the variables - in Java you can declare variables when you need it, so it is just as convient, plus you strict typing so you don't get to do dodgy operations on your data.
Polymorphism is great if you use it properly, but it can be a performance hog if you abuse it. With Eclipse (http://www.eclipse.org) I can create subclass by just click 2 buttons like that so no problem there.
Deferencing in for loops is coming in 1.5, but Eclipse writes the loop deferencing code for you:
1) int[] arr; (or whatever array you are referencing)
2) type for
3) Ctrl-Space
and it writes the for loop for you, so I can do it just as quick!
I can juggle a large quantities of data just like that - give me a CSV I use StringTokenizer, I can read a file with a few lines and println to a file using the same code I do output to screen (System.out is a PrintStream, and I can set that to whatever PrintStream I like)
All programming languages are born equal - it is just the skill and experience of the programmer - would you say a oil painter is better(or worse) then someone who use Photoshop? (hmmm probably a bad example)
...that was replaced because it could not be maintained?
Fine :-)
:-) I don't care. (I can write C as well mind you!)
I will keep writing my program in Java and you do it in C or Perl or Python
I only care when people say Java is rubbish, it is so slow, as a lot of people in here do.
I do work on developing certain three letter vendor's JVM (no names!) and I say a lot of Java myth is simple not true - we have a lot of happy customer.
Actually, you only missed by half of that... It's 15Mb. Another 15Mb mistake like yours and Java downloads *faster* than Flash.
Hahaha. Where did you pull your stats out?
So I guess that freshmeat.net and SourceForge are run by Java-loving dweebs? Check their language stats sometime...
Would you point me to bigger open source repositories?
But the reason it is uncool is because, outside of stuff written just for Java monkeys, there is no Free software to speak of written in it. Free software is written in C (65%), C++ (25%), and Python and Perl (all but the last 1%). Free Software coders have avoided Java for lots of reasons, including its not-really-portability, its bad performance, its hasty and stupid language and library design, its corporate 0wnedness, and their own resistance to hype and idiotic jargon.
Bullshit. There are 12436 projects on sourceforge.net in the java language folder. C and C++ each have barely more (13254 and 13440 respectively). PHP is fourth with 9201 followed by perl with 5321. Your percentages are crap. Java is more than double the popularity of perl there.
Where did most open source Xtreme programming innovation happen? java (JUnit, Ant, Maven, etc...)
Who has the best open source MS Office file format compatibility? java (POI)
Who has the best open source search engine? java (Lucene)
Who has the best open source MVC middleware solutions? java (Struts and/or Velocity)
Who has the best XML tools? java
Who has the best gui test editor? java (jEdit) [and yes, vi and emacs both SUCK]
Who has the best foss XForms implementation? java
Who has the best open source SVG implementation? java (Batik)
Most actively developed open source IDE? java (eclipse)
Frankly, most of the real innovation that is being done in the open source community is being done in java. Stroll on over to Apache Jakarta project and look around for a while.
But what advantages does it have over Perl, Perl 6 and Mono/C#? I already know Perl and Perl 6 should be easy to learn, but if it need more from a bytecode interpreted language I'll look at C#.
I also wanna learn OCAML and C/C++ and some assembly. So I don't see how I'm going to find time for Java in the near future unless Sun decides to GPL it to give me more incentive.
Yes, VB it is a clear management idiot proof.
"Java has considerably fewer surprises..thereby resulting in a language where you cannot really make your friends go ga-ga at amazingly brief programming construct"
The real problem here is that C++ is a mess. "fewer surprises" here means that it has largely inherited C++'s mess. Java's verboseness is the product of putting in too much, not too little.
"Java has been considered slow for ages." [but isn't now]
It's true that the newer Java compilers do well on benchmarks. But it still *feels* slow when I sit waiting for 60 seconds for a small Java applet to start up or when my machine starts paging because a swing applet eats up 100s of megs of memory.
"Java is a strongly typed language therefore you have to tell the compiler exactly what you intend to use. And if you make a mistake in the way you use it, the compiler has the guts to tell you that you were wrong."
The problem here isn't about developers not wanting to know about their mistakes, but that strongly typed languages make it impossible to cleanly implement (and sometimes to implement at all) powerful dynamic design patterns.
"Java has a vast library..."
Java's APIs are it's weakest point. They are horribly complex. I once had to work with the Java Advanced Imaging APIs. IIRC, it has over 300 classes and yet functionally wasn't significantly more usefull than Cocoa's 3 image classes. Whenever you need to get at anything (say you wanted to change a pixel), you had to use a dozen classes. There are even classes that you have to instantiate to create parameter lists in order to pass to the instantiation methods of other classes. While not this extreme, much of Java's APIs seem to suffer from a similar explosion of classes and complexity.
"Java is popular. Anything that is popular has lost its elite status and therefore is not cool."
So Coke, Nike, Doom3, the PS2 and the NBA aren't cool?
"Java is an application programming platform. You cannot do cool things like device drivers and games, etc (until recently - but Java gaming is coming in a big way)."
AFAIK, Java fell flat as an application programming language. Today it is primarily used a server scripting language, just like the "cool" languages that Paul Graham mentioned, such as Python.
most hackers like to whip up chunks of code to accomplish small tasks. java is terrible for little hacked together projects. nothing is more annoying when you're trying to write a 100-line program than being forced to handle exceptions that you could care less about.
What you can do is to *save* your interpreted code fragments. I know of at least one project that used this method essentially identifying small program segments and compiling these segments into native code.
I simply don't understand why Java programs don't do this and take advantage of the information they gather each time they run. In this manner you can actually make a *faster* app in an interpreted language sometimes because the interprater/compiler can benefit from the run-time performance of the program (i.e. better branch prediction etc..).
However, as a matter of fact I don't think java interprators save all this usefull state data. Why, I can't figure out.
If you liked this thought maybe you would find my blog nice too:
A couple of guys (I can't find the link) ported QuakeII to java to get this statistic.
This is a bit misleading. They implemented parts of Quake II in Java, but had not ported the entire application. As I read it, much of the more advanced AI aspects as well as graphics features had not yet been converted into Java.
No comment.
As the fortune file puts it, "A language that doesn't affect the way you think about programming is not worth knowing."
Learning C was a mind-expanding experience for me because it let me do anything I wanted and because it taught me about self-contained functions. Learning Smalltalk was a mind-expanding experience because it was this giant, full-featured language built out of a few simple principals. Learning Perl was a mind-expanding experience because it was this hideous, misshapen monstrosity of a language where every single wart turned out to make my life easier. Learning Lisp was a mind-expanding experience because you could extend the syntax of the language itself from inside the language.
And Java? It's basically just C++ with some of the better ideas from Smalltalk (or Lisp, Eiffel, Sather, Modula-3 or whatever) grafted onto it. Been there, done that, got the T-shirt.
That's not to say that Java isn't useful--it is. It's just not exciting. There are jobs for which Java is the right tool and some of those are even interesting from a hacker's point of view. It's just that the language itself that isn't interesting.
The only time I consider brushing up on my Java skills again is when I'm looking for a job.
(As an aside, my take on Paul Graham's comments is that if a company is looking for Java programmers, it's a bad sign because it means that the suits are making technical decisions. I'm inclined to agree with that--if the company is run by people who think Java is cool, you have to wonder what other kinds of decisions they are making.)
Disclaimer: I've done very little in the way of Java programming, although I did once write a compiler for it.
Windows 3.1, Windows 95, Windows 2000. The most successful software product line in history. Each was an almost complete re-write. Each re-write was necessitated by the predecessor being un-improvable (and no-longer-adequate). If we are talking market success, being re-written is a sign of success, not failure (since being funded to be re-written requires that the product made some money in the first place).
Posters recognized by their sig,
My favorite example of this is trying to write Java code to produce a datestamp in RFC2822 format. For example, Tue, 24 Aug 2004 16:09:23 -0400. Obviously this is something you want to do all the time when programming Internet stuff, and at least up until Java 1.4 it's ludicrously difficult to do. I usually cheat and force all timestamps to UTC to at least cut the code down to size a bit.
Perhaps some Java enthusiasts would care to try and come up with the shortest, simplest implementation of rfc2822DateStamp()?
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
I posit that the dependency tree for most java engines under most software distributions is too erratic right now, and not unified enough to encourage Java for the lazy programmer who doesn't want to depend on a software packaging specialist.
.msi AND .rpm or solaris .pkg for their platforms? Sure server environments will have specialists to do that, and for-sale software as well. But for free software advocates, that's a strength of the language turned into a weakness. You support multiple platforms, but you have no control over their policies and practices, so you end up with more work.
Software packaging specialists usually look at Java and faint(despite new inroads both by projects like InstallAnywhere and jpackage, which are definite improvements).
I can't wait for java package writers to automate package building the way dh-make-perl does on Debian, perhaps then people will see whatever power is in the language.
In the meantime, the work of getting say 15 java packages(including a jvm) on 50+ machines is a major undertaking using native system tools(meaning using scripting languages like perl to download a zip file on windows is cheating...)
How many cross-platform java developers can build
Now I'm not saying multi-platform java is bad, but I'm saying that Java could use a page from Debian's packaging book along the way. Managing/upgrading software, and tracking dependencies is an important task that affects developers directly, and most of them are specialists... in something else. Giving them tools(CPAN comes to mind, as a resource, but without structure, it helps less than it could), becomes a must. Being able to make re-distributable packages without a java ide OR reading a manual would help too. (Jars are libraries, not packages, in my book, they do not register with the system to simplify removal, and they can be bundled together for dependency reasons, that excludes them from the "package" definition.
Does this do anything to make Java cool? No, Java is already considered a "barebone" language, it can't be cool anymore, at least in some circles, it does all the good things, and it has no quirky restriction that would limit it to an elite. Can it be a good, useful language yes, can it be used in a bunch of situations? Yes
Cool? Java doesn't really want to be cool, it's disruptive to businesses.
If you are talking market success, point me to a few other significant Lisp-run websites, please...
Java is uncool for many reasons:
- When it first came out, there were memory leaks ALL over the place.
- Java is still sluggish.
- Most Enterprise-level Java apps are really, really poorly coded, hangs often and are extremely sluggish.
- There are STILL memory leaks ALL over the place. - Java is overused.
Oh, actually, I agree. I personally looove jEdit, and that's all I use anymore...
Yet, for bootsptrapping, it's python for me.
"Piter, too, is dead."
I'm sure that there are a lot of interesting web apps written for 8-bit processors.
The real problem is that Java encourages lessor coders to do the work
You won't get any disagreement from me there. I think of this in the same lines as VB, it allows people who shouldn't be coding to get away with murder. Honestly, I think VB/VBA is even more accomodative towards poor coders since the language isn't even strongly typed.
Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws-Plato
Java is still too low level for the enterprise. As for encapsulating business logic, it requires too much programming to get any of it done.
That's why people are still using (today!) Cobol, and the most successful large enterprise vendors have gone to developing their own 4GL-like environment and develop in those toolsets rather than Java.
I dare you to find a list implementation in any type-strong language that doesn't require an upcast in this situation. You need it to be able to store objects of an anonymous type on a list.
c++ using the stl doesn't need it, because their lists are stronger typed than java's.
std::vector<char * > l;
l.push_back("A String");
char *s=l[0];
Look no casts required - anonymous type doesn't sound like strong type to me.
You should put all your DLL files into c:\windows\system32, since that is on the path. Nothing could possibly go wrong.
In the beginning Java was billed as all the things it was not at that time, fast, fully cross platform, stable. Most of those problems have been tackled and most Java programs are OK in my book. Some my still say it is slow but as an OS unto itself it loads much faster than a bulking Microsoft OS does.
I think Java would have been farther along and a lot cooler if Sun had not made a deal with Microsoft to screw over Java. MS has done more against Java than they ever did for it and sun took it in the ass on that deal. I think that Java is just now emerging as to what it was intended to be. A cross platform programming environment. I actually use several Java programs that are fast loading and they get the job done. Thanks to those using linux we now have decent Java programs. With more people turning to Unix everyday I look forward to more and better Java programs in the future.
I don't dispute your post. But most of this is because Java is a language and a platform. Yes there are many benefits to Java, and the language is great. Its just that there is so much additional unusuable crap that, while the server programmers love it, desktop users have come to hate a lot of Java and its poor performance compared to the rest of the desktop.
orbitz.com (running http://www.itasoftware.com/) for one: see google groups.
Posters recognized by their sig,
- Difficult to do very simple OS specific stuff, like opening an html doc in the default browser.
- Takes a long time to start up the VM. If your program is trivially simple, the overhead dominates over actaully running the program.
- The Swing and AWT mess. It's gotten better, but I think Sun made some fundamental mistakes right at the beginning and they are unable to acknowledge these mistakes and unwilling to start over and do it right. They're a server and OS company. What do you expect.
- It's a lot harder than it should be to call natively compiled code from a Java program. JNI is a pain in the ass compared to other languages.
- EJBs.
Things that don't suck about Java:What really sucks is senseless language flame wars. If you're smart, (I mean really smart, not just self-agrandizing) it's a matter of choosing a good tool for the job. I would say the right tool, but there's often several good choices, as well as not-so-good choices.
It's interesting to note that Perl and Lisp are a lot alike, not so much in the languages themselves, but in their community. Both feature an intensely loyal following of programmers willing to overlook truely bizarre syntax in exchange for the ability to implement some advanced programming language concepts cleanly and consicely. Both languages are similar in their retention of some very strange artifacts of history: cons, car, and cdr, for example, or the parts of perl adopted from shell scripting languages. Some members of both communities tend to be a little too convinced of their own superiority. But, both languages really do have some cool features.
And remember: If Java is to Cobol what Python is to APL and if Perl is to Linux what Visual Basic is to Windows and James Gosling is to Larry Wall what Elvis is to Hank Williams Jr., can you doubt that we were made for each other?
-cbare
I have to say as a Java Programmer a lot of people end up with slow Java programs cause they are bad programmers not due to the language. Most people think oh Java I don't need to worry about pointers or memory usages it will take care of it for me, and they proceed to write absolute shit for code. The amount that I learned after 2 years of programming the language full time was amazing. You really need to understand what you are doing in the language when are generating garbage when you are doing stupid things like creating a vector with 10 elements and then trying to stick 10,000 objects into it, instead of presizing things intelligently to avoid all the memory copies. I also used to see a lot of stupid things like people copying arrays in for loops instead of using System.arrayCopy. Anyway I suggest people learn how to actually use the language before they blame the language for their own personal inadequiecies as programmers. Of course this is the slashdot crowd so most of you couldn't write more than 10 lines of code anyway. The only complaint that is valid I think is startup time. People should be running the server vm and there is a startup penalty you pay with it, but really if you start your application and it takes 2 seconds it isn't the end of the world considering you will get c++ performance. If you run the client vm you will get faster startup, but poor application speed. Also there are a ton of bad swing programmers out there, who either A don't understand multithreaded programming or B don't understand good gui design, or even worse both. I suggest people spend some time on JGoodies Website to learn something about good looking swing UI's.
Woo-hoo!!! That makes two. Well, one if you consider that Yahoo Stores moved on from Lisp...
The difference between a strongly typed language and a loose one like Java or BASIC (using Variant for all variables), is that the type can be checked at compilation time, instead of maybe possibly at run-time. This catches errors early, and is also more efficient. Java only supports heterogeneous collections (well, homogeneous collections of hidden pointers to objects), whereas in the majority of cases you need collections you should use homogeneous collections. If you intend to have a list of strings you should be able to say so, and the compiler should be able to check all references to the list and ensure the type is correct, rather than leaving it to the run-time library.
Yeah, I alluded to that at the end of my post (in my book, "automatic memory management" == "garbage collectors").
Also, in the example you give, you can know that a virtual method is never going to be overridden before runtime, you do need to link your .o files tho, so it is after compile time. THere is however no theoretical reason why you cannot decide at that time to recompile a bit of code to get the exact same optimizing as you could with java.
Can you do that if your output is a class library (.dll or .so)? This is an honest question.
When will people get over this idea that there is or even should be a language of the masses. The masses just want there shit to play music, watch their video or view porn. They do not want to have to program the machine to do it.
Java is not considered to be a write once and debug everywhere laguage for nothing.
Java is a strongly typed language therefore you have to tell the compiler exactly what you intend to use. And if you make a mistake in the way you use it, the compiler has the guts to tell you that you were wrong.
Leaving aside the fact that static typing and strong typing are not the same thing, there is more to life than FORTRAN vs. Lisp. Take, for instance, type inference --- which, at 20-odd years old, seems to be a little too cutting-edge for industry.
however, even if you were right about how a cache worked, youd be wrong in the argument. first off, malloc implementations usually scatter data just as much. though malloc can be implemented to stick all the data it can towards one end of the heap or the other, this results in an unacceptable level of heap fragmentation, and more wasted memory than you can shake a java-object-header-on-a-stick at.
also, most JVMs implement compacting garbage collectors. this means that most objects that have been around for a while end up very nicely packed into one contiguous area of memory -- something you wont ever get from C/C++, or any language implemented using malloc for allocation.
it shocks me that so many people who dont like java can only ever spout pseudo-facts about bad performance to bash on java; especially when there are so many actual barriers to using it in many situations. thank god you at least touched on lack of good, widespread VMs for portability.
and btw... its probably a bad idea to bash something for corporate 0wnedness in the same paragraph that you bash it for lacking market penetration. tsk, tsk.
C (23%), C++ (23%), and Python and Perl (all but the last 21%, which is java)
How about C++? When you make a new object in C++, are you saying the fact that the new object is referenced by a pointer is bad?
rm -rf sig
No need to get personal here. There are thousands who would agree with my "myopic" viewpoint as well.
Why waste time building an application that is going to be bullet proof - when you will only use it once or twice or for a clearly defined purpose?
I contend that these are not mutually exclusive. Static type checking is not a detriment to "quick and dirty" programs, and in fact, is even more helpful in such cases, because it's less likely that extensive testing will be done on them.
Java is uncool for some of the same reasons that X windows is uncool. Too much time is spent on capabilities that most users don't care about when they could have been spending that time on capabilities users DO care about.
Platform independence is for the most part, a convenience to the creator or marketer of the program, not the user of the program. With relatively few exceptions, users generally only want to run a program on one computer. Even if they have multiple computers, they usually have them configured for different purposes.
I learned something important years ago in the Apple II/Atari/C64/Amiga, etc. days when video games for home computers started to become multi-platform. What I learned was, if you buy games that run ONLY on your particular platform of interest, they'll be more likely to take full advantage of your platforms specialties, which is why I bought the particular platform in the first place. The least-common-denominator phenomena really divided the GREAT games from the mediocre ones. As a user I noted which games were multi-platform and which were single-platform, and it was the single-platform games that made the best use of my hardware. Guess where I spent my money?
Today, despite claims to the contrary, computer language still matters. Not many programs are written all in assembly language anymore, but if I come across one, I'll certainly take notice. Such programs will be blisteringly fast and have a very small footprint. No matter how much CPU power and memory you have, there is always a benefit to making something smaller and faster. And while few programs are in assembly any more, the OPPOSITE extreme is Java and .Net, and as soon as I see a program that seems like it may be interesting but I find out it's written in Java, I now tune it out as a matter of course. Slow, glitchy, incompatible, THAT'S ALL I'VE EVER SEEN in Java. Of course, I don't keep a finely tuned latest-rev-level Java VM on my system which probably would make a difference, but that's not what I want to spend my time doing. Developers who do, immediately make themselves completely out-of-touch with their user's experience and consequently, can't see what the problems are.
All Java developers should have a low-powered PC configured with the oldest and buggiest Java machine they can find, and run all their apps over the net using a 56K modem. Then they may have at least some idea how their app may be running out in the real world...
Don't know about BSD but under Linux you link against glibc (LGPL), under Windows (mingw) you link against mscrt.dll (MS EULA). In both cases you can distribute your hello world code binary only, as long as you don't change either glibc or mscrt (ha!). I guess something similar holds under BSD.
Or you could just say fuck it and allocate stuff all over the place on the heap and just leave it hanging out there as objects get created and forgotten.
Based on the code I just inherited at work that's perfectly acceptable, I'm just saying.
Glonoinha the MebiByte Slayer
The latter is the real problem: by far the majority of projects on sf.net are empty shells. To tell what real Free Software is written in, you have to identify the software that is really being used, and then not just count projects, but count lines of code (or, better, kbytes of object code). Of course, that's work, and hasn't been done since RH 7.1 was current. Even then, the raw numbers count all the Java wankage.
So, try to think of Java programs that are used by anybody but Java monkeys, and that work. No, Eclipse, Jedit, and web server add-ons don't count. What are we left with? Some Windows bittorrent client? Anything else out there? Hello?
3. Assembler (not really a language, but what the hell).
Definantly not a language. You might have been thinking of "Assembly".
Then again, maybe you weren't...
Required reading for internet skeptics
> Can you do that if your output is a class library (.dll or .so)? This is an honest question.
.so or .dll in your project and try this, but it will very likely break whenever some other binary tries to use this shared library, so not a good idea at all.
First of all, it is purely theoretical, I am not actually aware of a compuiler doing this automatically but I have done it manually as a result of verbose compiler output a few times.
It is something that you can do well for anything that you have the source for and that is statically linked into your binary. You cannot do it that easily if at all for something that is linked dynamically, if only because in that case the actual linking happens at runtime, so after you do your optimizing, while compilation is completely independent of your project.
You could include a
So, not for shared libraries, but if you build statically linked libraries specifically for this project you can.
What this of course gets you is a situation where if you have a shared library that implements a class with a virtual method, the runtime environment cannot do anything with the knowledge that it is not overloaded. This of course is different when running JAVA in a JVM.
If you were to run C++ in a VM, you would not have this limitation either, while if you were to run JAVA compiled to a native binary you would get the same limitations.
One of the reasons that some consider Java uncool, is because of the myth that Java is slow. I call it a myth, and I will try to explain why it is a myth. (Actually, in theory, Java will outperform C++ soon).
Just to take a swing at another myth, while we're at it: When it comes to size of the stack, how you want the garbage collector to use memory etc., you CAN in fact give the JVM parameters to control this stuff.
Java isn't slow anymore. It may be true, that (small) Java applications generally takes a little longer to start up, if you didn't use an AOT compiler (like for instance the "free as in freedom" compiler GCJ or the more mature but proprietary Excelsior JET). Its true that early versions of Java were slow, but 1.4.x isn't generally slower than C++, in fact, I wouldn't be surprised if it outperformed C++ on general terms one of these days.
One of the things that makes Java "not slow", is actually the way memory is allocated. Its rather cheap to allocate memory in Java, compared to other languages, and its even cheaper to "free" memory, since you don't do it, you have the cost of the garbage collector instead. The garbage collector in Java is very fast, compared to older garbage collectors.
(For the interested, IBM has an article on "garbage collection in the HotSpot JVM", and another article that explains various garbage collection techniques, and finally they have an article that covers performance concerning garbage collection. They have a lot of other interesting articles, but I don't want to list all I know, if you like to check it out, here is the search I used to "refind" these articles.)
I make the claim that Java isn't slow, but don't just take my worth for it. (Not that I think you would). Go search on google or whatever. A word of warning though .. since older Java's were
indeed slow, do note the version of the Java tested. It should be (at
least) 1.4.x. I don't think 1.5.x is stable yet and I dunno if its
faster or slower, but 1.4.x have a real nice enhanced garbage
collecting subsystem. (Esp. 1.4.2 and above).
(On purpose, I didn't go for SUN benchmarks, as they might be (considered) biased, but sun does have a word to say about "Java Performance".)
Here is a couple of quotes from an article that considers performance of Java vs. C++, analysing some benchmarks of Java, C++ and other languages. While the article was updated this year, I was still unable to find a link to a benchmark diagram of the current 1.4.x JVM. It seems though, that the 1.3.x wasn't too slow, even without latest optimised GC-subsystem, which is one of the key factors that makes 1.4.2 faster.
Here are the quotes:
Declaring variables - In Java can only declare them at point of first use if they are local. Not class member variables, then you need to scroll to the top of the class declaration.
Polymorphism can be a performance hog with what language? My point is that in Python you can always hack an existing class from the outside because you can arbitrarily hand extra member variables off a class, or even off a single object of a class, and no data is private, so there is nothing you can't touch from the outside. None of this is performance hogging, it costs no more than if it were done within the class.
Your description of juggling data was pedestrian compared with the kind of data juggling I was talking about. I'm talking about complex manipulations of complex data structures in memory with a very few sparse lines, and no need to use libraries.
I certainly don't agree that all languages were born equal. That's as useful as saying every person is born equal. In some ways they are, but every person is better in some skills than others, just as some languages are better in some problem domains than others. There is no doubt in my mind whatsoever that Python is a quicker and more pleasurable hacking and prototyping language than Java - provided you are not doing a GUI prototype. It's also very suitable for in house production code. But for commercial production code, I'd go with Java or C++, depending on problem domain.
Have you tried coding with Python? I can heartily recommend trying it if not. Yes, I've tried Java, but never got that deeply in to it. But enough to know what problem domains it's best for.
is it cheaper to buy a faster system, or develop something in c?
time is a resource thats more valuable than memory and processors..
I never said that I can't understand Lisp, only that my code tended to be undreadable (at first glance) after a while when using pico to do my text editing, when working on a large program (the 80 char wrap on the terminal I was working on did not help.) Everything was UNIX command line in the classes I took, which made the edit, load, run, and debug process rather tedious - at least to someone who was used to coding in a GUI ide.
I'm quite proud of the fact that I learned Lisp, and that I learned it the RIGHT way (ie, using recursion). Lisp is quite elegant, but it takes some thinking to code simply - a good form of mental training, no matter what language you code in.
That is NOT what reference books are for. Or at least, that's not a very efficient way to use them, even if it's often how you have to learn a language. Reference books are really for when you are already familiar with a library/API and you have a general idea of what you want before you're looking it up, or when you just need to brush up on something real quick.
If you don't have that pre-existing degree of familiarity, you're likely to do a lot of useless programming based on assumptions and instincts that are not applicable to the current platform. You put time into setting things up expecting the API to expect one thing, then you look in the reference guide, see that it wanted something else, and have to go back and retype a few lines of code.
Yeah, it's only a few lines here and there, but they add up until eventually it probably would have been cheaper to just code the thing in xxx less Perfect For The Job(tm) language from the beginning.
The issue is not that people shouldn't switch languages, ever. The issue is that if two languages, APIs, whatever are close enough in capabilities, it's a waste of time to go switching languages every time one fits the task better.
Let's do one from the classic tools class of analogies: Let's say I need to open a box that's taped shut. I have a choice of doing it with a box cutter that's sitting on a table on the other side of the room, or my house key that's in my pants pocket. Yeah, the box cutter may be custom made for the job and all, but I'll use the house key anyway. It takes me less effort to pull the key out of my pocket and mangle the box open than it does to get up, walk across the room, get the box cutter, and come back.
It's the same with languages. If there's one that I'm used to but isn't just perfect for some small job, I'll still use it if I'm not just really familiar with some option that is generally better, because it will take me less effort to mangle the solution together with the language that I'm a pro at than it will to use the Better Option(tm) but have to lean on a reference guide the whole way.
This has nothing to do with how a Real Programmer or a True Hacker would do it (re: a suggestion from an AC a few levels back on the discussion). It has nothing to do with pride, or ideals, or what the boss tells you to do. If you have to go with what the team says, or you have to nurture a sense of geek honor, or you want to learn a new language, or whatever else, go for it. I end up doing that all the time. I'm just saying what the path of least resistance is assuming there are no other circumstances.
Yeah, your're right. My braincells were dozing.
I remember writing something to aggregate and analyze the results of a survey conducted by the weekly newspaper where I worked at the time. I wrote it at home, in my kitchen, on my trusty Commodore 64 using the BASIC Commodore bought from Microsoft. I.e., one of the predecessors to GWBASIC. It was also, effectively, the OS for the C64. Lotsa line numbers. (Once I got the survey code working, guess who got to do the data entry?)
-- Slashdot: When Public Access TV Says "No"
That such obvious FUD (other posters have proved the issue with statistics from freshmeat and sourceforge) can be modded as "Insightful" is an utter indictment on the general /. attitude towards Java. This indicates an unreasonable hatred of Java to the point of telling out and out lies about the language.
/. member for quite a long time, and I used to think it was quite cool, but now it's just a home for bigots (whether language or OS bigots, I don't care)
I've been a
Find, find me ONE commerically available ( NON-GAME ) application that you can buy at bestbuy, office depot, staples, CompUsa,
.NET does right now ? .NET does not have a multi-app virtual machine. You are confusing it with spawning which even Java can do.
.NET-ified, or .NET is OS-ified
.NET runtime by default in Longhorn much like the visual basic libraries are today (and still will be in Longhorn). Probably become another gaping security hole. Your point?
MoneyDance and pdf-Office are two I know of. Its hard telling since no one generally advertises what they made their product with. Whens the last time you picked something up at Best Buy that stated it was written in C++?
actually READ some of the links that are as a result the google search
And hey....go use Google yourself. If you want to show me something try posting a link next time. And heres a novel idea: make sure its a working link if you do. I have better things to do rather than follow down 5000+ links or go searching Google because someone else is too lazy to and keeps posting "its in google I swear". Hell, Im sure you can find pictures of a three headed cat out there if you look hard enough kid.
Oh, and about multiple apps within the same JVM...you mean what
At which point we'll be staring at impending LongHorn, where THE OS is
Yes, Microsoft will probably install the
No further comments.
I once wrote for and maintained code for a 68000-based realtime parallel computing system. The individual computing nodes were pretty spare, but they ran Fortran code that was cross-compiled on a VAX, and then loaded into the compute nodes' memory. As a real-time data acquisition system, the application and OS were pretty much the same thing. Fortran is good at array/buffer processing, and the great math and science libraries available for it meant that you could do real data analysis right in the data acquisition stage of the pipeline. That was important for filtering out junk data and keeping throughput down to a level that the tape drives could keep up with.
Object casting is not a "feature." It's probably the biggest design flaw I can think of in Java.
The object casting in Java completely destroys any benefits of static typing. Casting does not cause it to fail early. It only fails compilation when you fail to specify the casting. By explicitly performing an object cast in my code I'm basically telling the compiler to ignore the static typing and delay the cast until runtime. When you run the application it's still quite possible to have a ClassCastException.
OFF-TOPIC POST
Does anyone else remember the series by Stephen R. Donaldson, The Chronicles of Thomas Covenant the Unbeliever, and its sequel series, The Second Chronicles of Thomas Covenant?
Well, its being continued in The Last Chronicles of Thomas Covenant, and the first volume (of four) comes out on 14 October 2004! Read an excerpt here
I've submitted this twice, but the powers-that-be aren't well-read enough to recognise it as newsworthy.
Neopets - the best free game on the Int
This is valid Java:
:-) so there is never an incentive for me to try Python....
class A {
public methodA() {variableA = 100;}
int variableA;
public methodB() {variableB = 10.0;}
double variableB;
}
But why would you want to do that? it makes things so much unreadble....
When you write code you want to expose certain interface but not everything - I want to keep some variables private so that no one would depend on them when I decided to change the implementation!
Complex data structure is piece of cake in Java - there is no need to worry about pointer, you just need to put all you need as class variables like Python and I find it a lot easier to do complex data structure in Java then in C!
Well Java, C and Perl served most of my need
Anybody who likes Java should spend two days with Python or Ruby. I can guarantee your appreciation of Java will diminish.
Java lacks the following:
first class functions(except by reflection, ugh)
anonymous functions, closures (except by using objects), multiple assignment,list literals,list comprehensions, co-routines or generators, multiple dispatch, A decent iterator mechanism (I know wait for 1.5), Templates (I know wait for 1.5).
Even templates, however, in a statically typed language make writing generic functions far more ugly than in a dynamically typed language.
Java forces everything to be an object. I find objects useful sometimes and sometimes I would rather just create a function.
Java makes some things irritatingly more verbose than say Python or Ruby.
Python examples:
list literal:
l = [1,2,3,4]
list comprehension
build a list of squares:
[x*x for x in range(4)] ==> [0, 1, 4, 9]
passing a comparison function to sort
def coord_cmp(c1,c2):
"""compare coordinate 1 to coordinate 2
sort top to bottom left to right"""
x1,y1 = c1 #multiple assignment
x2,y2 = c2
#cmp is built-in, returns -1 | 0 | 1
if y1 == y2: return cmp(x1,x2)
else: return cmp(y1, y2)
#list of coords
l = [ (5, 11), (1, 11), (3, 10), (5, 10) ]
l.sort(coord_cmp)
l ==> [(3, 10), (5, 10), (1, 11), (5, 11)]
#looping
for x,y in l:
print x,y
3 10
5 10
1 11
5 11
#using zip to combine separate lists
x_coords = [1, 10, 20, 30]
y_coords = [100, 200, 300, 400]
for x,y in zip(x_coords, y_coords):
print x,y
1 100
10 200
20 300
30 400
#reading from a file
#python has plenty of file operations, this is
#just a simple one.
f = file('xyz.txt', 'rt)
for line in f:
print line
f.close()
#a generic function. works on strings, ints, floats.
def max(l):
max = -sys.maxint - 1
for x in l:
if x > max:
max = x
return max
Of course max() is already built in
Spend a day reading the tutorial.
http://docs.python.org/tut/tut.html
But I think he misses a really, really important point about both checked exceptions and static typing. In a data structures class in college, the professor suggested that we think about a program not as a way to tell the computer what to do, but as a way to tell other people what we wanted the computer to do. In this regard, checked exceptions and static typing are a huge help.
I've been a big Python fan for years, and I recently used a big Python codebase for a project. I found it hard to figure out what was going on and how I should use it, in large part because I didn't know what the constraints were on parameters to pass to functions. If they'd been typed, I would have known what methods they needed to implement. Of course, I could read the code, and that's what I did, but it's a lot harder than reading the javadoc (or docbook or pick your favorite automatically generated docs for C/C++ or Java).
Similarly for exceptions: if there are no checked exceptions, then as a user of a piece of code, I have no idea what exceptions it might throw. (Yes, if unchecked exceptions exist, I'll never know when they can be thrown.)
Of course, we could overcome all these problems with documentation. And if you believe that, I've got a bridge to sell you...
"C is faster then other languages. If you want speed use Assembly. Enjoy debugging that code and good luck trying to read it in a few months."
Maybe it's just me who thinks that Java may be doing to C/C++ what C did to assembly
I mean think about it...10 years ago programming in assembly was much more common, and C/C++ was used mainly when programmer productivity or portability was more importent then speed. Now the same is becoming true for Java.
I don't know if I could say Java is uncool. The debugger is
a pain in the ass sometimes, not letting you do something
perfectly sensible in other languages, but I can usually get around them.
The company itself perhaps...
Didn't Sun recently settle with Microsoft and now they
are doing road shows together?
Didn't Sun buy a SCO license for Solaris?
Have you read the licensing agreement for the Java desktop 2?
Non sequitur: Your facts are uncoordinated.
...by the way Google is hiring senior Java software engineers....
You can now [finally] open an html doc in the deafault browser.
JDIC, Java Desktop Integration Components provide more integration into the host desktop environment: integrating the native web browser, mail, registered document viewing applications and installation.
Includes things like a file browser, tray icons, and Screensaver SDK
https://jdic.dev.java.net/
Very nice explanation, however, I don't think it is that applicable to Java. In particular the interpreted language can benefit three ways, either explicit runtime hints to the interpreter (which java doesn't seem to have), passive learning by the interpreter (branch prediction etc.. etc..), and tuning to the particular processor/machine.
While the last really is a benefit java posesses the other two aren't that relevant. In particular Java is going to be slow because most JIT or interpreters I know of don't seem to remember things from one instance to the next. Probably if the interpreter/JIT saved branch prediction information, profiling and even small compiled native segments it would be much faster but to my knowledge no java implementation does this.
If you liked this thought maybe you would find my blog nice too:
While many people on this board seem skeptical of fast interpreted langauages it really can be accomplished. The problem is that most modern interpreted languages don't bother with these optimizations.
I heard of one interpreter designed to emulate another processor architecture which could sometimes run code for the emulated architecture faster. That is sometimes you would get a speed improvement by compiling the software for the secondary architecture and then running it through the interpreter rather than just compiling it and running natively.
How can something like this work you might ask? Well in the following way. At first the instructions would be entierly interpreted (and thus much slower) but during program execution frequently executed chunks of code would be identified and converted to snippets of native code. Henceforth when this code section was encountered rather than emulating it again control was simply transfered to the pre-compiled piece of code.
This might seem like no better than a JIT compiler but the important difference is that these code snippets and various profiling and branching information would be saved between program executions. Thus after a program had been used frequently it would end up being quite fast, sometimes even faster than native code.
How can this code be faster? A couple reasons. First of all since this 'extra information' was just a local cache it could be optimized to the specific architecture/chip without any fear of compatibility issues (if you find your architecture has changed just whip this cache and go back to interpreting). This means that the code snippets it generates can be evaluated on the machine they run on to see what generates the fastest results (so a program might end up running differntly on a system with a fast memory bus than a slow memory bus).
Secondly real profiling information can make a big difference. Not only does this allow the interpreter to make good branch predictions it allows for a whole new kind of optimization. For instance one might have dynamic loop unrolling where the interpreter has saved code fragments corresponding to 10 itterations of the loop and one corresponding to 5 iterations and one corresponding to 1 iteration. When it realizes it is about to enter a loop with 66 iterations it runs the 10 iteration segment 6 times the 5 iteration segment once and the 1 iteration segment once.
As far as I understand it compared to schemes like this Java interpreters/JIT systems are pretty bad. So long as you don't save a cache of compiled program segments and profiling data you are usually going to be slower than compiling.
Personally, I think this would be a wonderfull concept to design an OS around. The operating system would have a standard virtual machine most programs would coded in...or perhaps several VMs one for java another for mono etc.. Each executeable would have two forks, the first would be the actual code in whatever virtual machine the second would contain a cache of code snippets and profiling information on the current machine. It would also have the wonderfull property that new OS updates could actually make your old programs run faster (better optimization algorithms).
Can someone tell me why this sophisticated sort of technology isn't being used for java? Or is it and I am just missing something?
If you liked this thought maybe you would find my blog nice too:
With regards to developing web applications: "Needless complexity" sums it up.
Steve Magruder, Metro Foodist
Does anyone else see the irony in a statement by a geek about something that is used to impress other geeks as 'cool'?
Or is it just me?
"I have been around the world and found that only stupid people are breeding" -- Harvey Danger
YES, My apps are restarting.
... start them again.
Of course they are restarting.
As an engineer, what I *do* is write apps, start them, test them, make changes to them, and then
Maybe you are right, that startup time doesn't matter when running applications.
But it sure as heck *does* matter when you are developing them.
Maybe Java is cool for people who run applications? As a developer, I have to say, it's not cool for me. I can't drink enough tea/water/whatever or find enough else to waste time on while I'm waiting for the JVM before I can do more work.
-- Terry
"But why would you want to do that? it makes things so much unreadble...."
:-) so there is never an incentive for me to try Python...."
;-)
In Java maybe. Here's Python:
class A:
def methodA():
self.variableA = 100
def methodB():
self.variableB = 10.0
Nothing unreadable about that. But in Python, you can also do this:
myA = A()
myA.methodB()
myA.variableC = "Hi"
At which point the object myA has both a variableB from the class function call, and a variableC tacked on to it from outside the class. Very useful when hacking. Of course in Java, you could have container class to hold the object and the extra data, or you could could subclass. But for quick experiments this saves time. And of course if a library creates the object itself, subclassing wont help you, and if it's buried in a data structure that the library has constructed a container class won't help you either.
"When you write code you want to expose certain interface but not everything"
Not in a quick hack or when prototyping. Which is what we are talking about as a problem domain. More specifically, when doing a quick hack, you don't want to have to make changes to a library class that you want to leverage. If the author of that class (in Java or C++) hasn't made a certain member variable or function public, you are stuck.
You're missing the point about the ease of juggling data in Python. I know what it's like in both languages, and it's not in the same ballpark, I assure you. If you don't know any Python or Lisp, you won't realise the difference. It can be easier and more natural than Java, I assure you.
"Well Java, C and Perl served most of my need
Nor me for years after I'd heard of it. Then I had to maintain a bit of someone else's Python code, and I've never looked back. Sorry for evangelising, but it was a great discovery, and like any new convert I want to share...
Java made it's way into the web paradigm. In the last 6 years I've never seen a web or any Java application taken nearly as seriously as anything I've been asked to do in C/C++. They just don't expect you to work as hard in the Java world. Anyone can do it, so it must be easy. If you're working hard at it you must suck.
- Sig this!
Simply put.
Hello World - C or C++ less than 60k compiled.
Hello World - Java - Approx 7MB.
Bloat - Absolutely.
Slow - (At startup, or jsp recompile) Absolutely.
Have a crash in a java application - welcome to a nightmare trying to debug it, especially when it's not necessarily in the "application" that was developed, but in the application server, due to someone writing (or building it) on the wrong java version, or with the wrong garbage collection...
It might be more difficult to build an application from the ground up in C or C++, however, usually, in the end, it's a lot more stable.
Performance for an interpretive language, vs. a compiled to native machine code program is night and day.
If you want to write programs that perform functions all day long and need to stay in memory... write daemons.
Add to that the following issues.
Version compatibility.
Between JVM Versions.
Between JVM Vendors.
Implementation compatibility.
Between JVMs.
Between Application Servers.
And now we have even more headaches than when we dealt with simple C compiling issues, imho.
Who is general failure, and why is he reading my hard drive?
....
...p..............
......b...w...
BAHAHAHAHAHA!
BTW, here's a couple of pages that show equivalent Python and Java snippets. They illustrate better than I have been describing how much easier it is in Python to hack something together quickly. And the result is far more readable too.
n -v s-java.htmlb log/2004/04/2 9.html%23P36
http://twistedmatrix.com/users/glyph/rant/pytho
http://www.pycs.net/users/0000323/we
Ever tried to hack together a prototype of something that uses other people's code? For a number of reasons, unless the code you're using was designed to be hacked that way (which never happens), Java just makes it more of a pain in the a**.
Why should I have to screw around and remember if I declared x or X.
Derivative systems - no big deal. I've worked in telco, supply chain management and finance fields - they are all the same except for the fact that the derivatives-related managers wave more money around, yell louder and have the biggest hissy fits. (And you talk of programmer prima donnas.)
Who do you think writes the very software frameworks that allow your B coder drones to plug away on day after day? Gee, I dunno, could it be... the A coders? You've likely inherited a successful software infrastructure from a buckaroo that came before you and you are merely milking and taking credit for it. And in spite of the great software you inherited it probably takes you six months to roll out the most minor feature and you think it's a huge victory for mankind.
Thank you for keeping the world running. I really appreciate that.
Maybe I'm missing the point, but why do languages like LISP and Python have rather weak IDE's? No disrespect to emacs, but it seems to have stood still in the face of huge leaps in the quality of IDE's for other environments. I believe Java combined with a next-generation Java IDE (Eclipse or especially IntelliJ) can recapture much of the productivity that's supposedly lost to Python's terse syntax. Intelligent code completion gets around Java's rather wordy way of doing things, and refactoring support makes supporting that verbose code a breeze. IntelliJ is smart enough to figure out if you have a variable, what type it is once you declare it and can offer constructors to instantiate it without you having to do all the typing. IntelliJ can even find redundant bits of code and refactor them into a method for you. One of Python/LISP's main attractions is the interactive environment. Java's hot swappable classes combined with IntelliJ's debugger allow you to experiment and play around with your classes while your program is running, all the while inspecting your data structures, having conditional breakpoints, evaluating arbitrary expressions on the fly, etc. Really quite amazing how far java debuggers have come in the past few years. Plus java's remote debugger makes attaching to an already running process as easy as debugging locally which is great for debugging complex server side stuff. Checked exceptions is a big problem for Python0philes. You can get around that in Java by throwing RuntimeExceptions, but some find that sloppy. The right way to avoid having to declare a boatload of exceptions from a method, is to catch low level exceptions and throw a higher level exception (e.g. your library catches IOException, SQLException, throws LibraryException). I've got IntelliJ set up with a template to generate a new Exception with one click and just fill out the name of the exception, and, viola, you've got your higher level LibraryException and you've forever liberated your users from having to worry about an IOException when calling your method and allow them to do more sensible generic error handling. IntelliJ/Eclipse has tight integration with a number of standard tools like Ant (for builds), JUnit (for unit testing), XDoclet (for code generation), as well as plugins for tons of open source projects (by untalented non-hackers, according to the esteemed Mr. Graham) that make the task of getting work done a little easier by keeping you from inventing the wheel. So what you're left with is an IDE that can compensate for Java's supposed weaknesses and lets you enjoy Java's strengths, which have been enumerated by numerous prior posts (Robust Libraries, Strong typing, standardized Unit testing, standardized build tools, platform independence, strong documentation, very few nasty surprises). Which leaves me to wonder why, with all the great productivity and mind expanding power of Python and especially LISP (which had every f*cking feature back in '57 with McCarthy), do we struggle with vi or emacs, several slightly incompatible versions of LISP, shitty IO/concurrency libraries (for LISP), poorly documented libraries that you're not sure will work until runtime and even then may die on you unexpectedly in production when you blindly pass in some unexpected type, with decentralized pockets of apis scattered across the web in various states of disrepair? Java libraries seem to be a more organized affair, certainly from a documentation standpoint (the power of strong typing, checked exceptions and Javadoc are underestimated in my opinion and is one of the unsung features of the Java language) than most Python and certainly LISP libs out there. Why can't there be an IntelliPython, or IntelliLISP. My point here is not to bash Python or LISP or any language. I have done a bit of work with scripting testing with Python (Jython actually) and am making an effort to learn CLISP (from Paul Graham's ANSI Common LISP), if only to deepen my programming knowledge, through "bottom up programming" , macros, functional programming, etc. But, if I'm going to make the effort to learn a new language, I don't want to go back to the dark ages of friggin VI or emacs just coz Paul Graham says I can have better living through macros. It's the tools, stupid!
Now wash your hands.
Sorry for the bad formatting, try this one:
Maybe a missing the point, but why do languages like LISP and Python have rather weak IDE's? No disrespect to emacs, but it seems to have stood still in the face of huge leaps in the quality of IDE's for other environments.
I believe Java combined with a next-generation Java IDE (Eclipse or especially IntelliJ) can recapture much of the productivity that's supposedly lost to Python's terse syntax. Intelligent code completion gets around Java's rather wordy way of doing things, and refactoring support makes supporting that verbose code a breeze. IntelliJ is smart enough to figure out if you have a variable, what type it is once you declare it and can offer constructors to instantiate it without you having to do all the typing. IntelliJ can even find redundant bits of code and refactor them into a method for you.
One of Python/LISP's main attractions is the interactive environment. Java's hot swappable classes combined with IntelliJ's debugger allow you to experiment and play around with your classes while your program is running, all the while inspecting your data structures, having conditional breakpoints, evaluating arbitrary expressions on the fly, etc. Really quite amazing how far java debuggers have come in the past few years. Plus java's remote debugger makes attaching to an already running process as easy as debugging locally which is great for debugging complex server side stuff.
Checked exceptions is a big problem for Python0philes. You can get around that in Java by throwing RuntimeExceptions, but some find that sloppy. The right way to avoid having to declare a boatload of exceptions from a method, is to catch low level exceptions and throw a higher level exception (e.g. your library catches IOException, SQLException, throws LibraryException). I've got IntelliJ set up with a template to generate a new Exception with one click and just fill out the name of the exception, and, viola, you've got your higher level LibraryException and you've forever liberated your users from having to worry about an IOException when calling your method and allow them to do more sensible generic error handling.
IntelliJ/Eclipse has tight integration with a number of standard tools like Ant (for builds), JUnit (for unit testing), XDoclet (for code generation), as well as plugins for tons of open source projects (by untalented non-hackers, according to the esteemed Mr. Graham) that make the task of getting work done a little easier by keeping you from inventing the wheel.
So what you're left with is an IDE that can compensate for Java's supposed weaknesses and lets you enjoy Java's strengths, which have been enumerated by numerous prior posts (Robust Libraries, Strong typing, standardized Unit testing, standardized build tools, platform independence, strong documentation, very few nasty surprises).
Which leaves me to wonder why, with all the great productivity and mind expanding power of Python and especially LISP (which had every f*cking feature back in '57 with McCarthy), do we struggle with vi or emacs, several slightly incompatible versions of LISP, shitty IO/concurrency libraries (for LISP), poorly documented libraries that you're not sure will work until runtime and even then may die on you unexpectedly in production when you blindly pass in some unexpected type, with decentralized pockets of apis scattered across the web in various states of disrepair? Java libraries seem to be a more organized affair, certainly from a documentation standpoint (the power of strong typing, checked exceptions and Javadoc are underestimated in my opinion and is one of the unsung features of the Java language) than most Python and certainly LISP libs out there. Why can't there be an IntelliPython, or IntelliLISP.
My point here is not to bash Python or LISP or any language. I have done a bit of work with scripting testing with Python (Jython actually) and am making an effort to learn CLISP (from Paul Graham's ANSI Common
other posters have proved the issue with statistics from freshmeat and sourceforge
They've given a data point, not a proof. My guess would be that the fact that Java is very popular on Sourceforge and Freshmeat, but about 0.5% on RedHat (and less on the Debian survey, but the age of the Debian source count could account for part of that), would be that people learn Java in college and run out and write programs in it, but the people who write the programs people actually use tend to still write them in C and C++, or at least haven't started rewriting old programs in Java.
AaAaAJKLR:gh flash backs... flash backs! don't try and develop anything in flash! the code... goes... missing!!.. it just disappears!!!! really! macromedia deny all posibility of this happening - it's very intermittant and we haven't been able to provide a solid test case yet i would find a link about this but i have sort of psychologically blocked out that part of my life it's a joke! stay away!!!
c++ is really quite 1337 to any of that java stuff.
or Visual C++ for that mater.
and of cource c shuder dont even rate agenst good ol
ansi c++ with g++.
That'd be Erlang.
The FA missed the point rather badly, IMO - what makes Java 'uncool' is its lack of support for abstraction. When a programmer finds himself doing the same thing again and again, his first thought is "can I abstract this pattern?". In Java, the answer is all too frequently "no", and the programmer is forced to type in several lines of code to express one conceptual construct.
Sun's big mistake was in not separating the ideas of Java and the JVM more cleanly when marketing it - there are some very cool, hacker-friendly JVM languages (most notably Scala), all of which share Java's virtue of "compile once, run anywhere", but which have got practically no mindshare.
YES!!
.bat wiz would come along and show the light! Cheers!
I was hoping a
std::disclaimer<std::legalese> sig=new std::disclaimer; sig->dump(); delete sig;
Nice, but overkill for traditional applications. My OS security (I run Linux for almost all real work) should be sufficient to protect local executables.
When's the last time your exe's were examined for correctness?
When they were compiled. With Java's safety features, most nasty unintentional problems don't happen, period. Further, gcj will compile java bytecode (already verified).
As I'm sure you know, Java programs don't run in a sandbox and can do just about anything to the local system, just like any other program. Bytecode verification won't help if it's out to do something malicious.
If you knew what Java were giving you you'd be very happy with it.
I'm quite aware of (and happy with) what Java is giving me. That doesn't mean I don't want more...like fast program startup and blazing runtime speed.
Why Java is unCool is because Windows Geeks are the Laziest bunch of programmers on the planet, and they do NO RESEARCH on anything other then the Simpleton coding paradiem Microsoft provides.
If you bothered to actually read the article, it's about why LISP programmers in particular, and OSS programmers in general, think Java isn't "cool". Stupid article, BTW - go check SourceForge for how many OSS Java projects there are.
Many "top hackers" like Java, simply because it is a fairly logical evolution of C, unlike C++ which is a mess. Java is well suited to large scale software development, and is quite productive as well. Advantage: Java. How many new LISP projects have you seen lately? ;) Sheer envy is the problem here.
By the way, you .NET Programmers should be KISSING SUN'S BUTT. If it weren't for Sun you'd still be coding in VB6 and Com+.
Bzzzzt. Thanks for playing.
Galileo: "The Earth revolves around the Sun!"
Score: -1 100% Flamebait
But then the problem is that I want my prototype to be scalable and usable so that I don't have to rewrite the code after the prototype, or with little modification. I don't see the need for a prototype language - With a good Java IDE (cue Eclipse) I can do pretty much all the prototype easily - so why bother to write in Python to prove that it works then have to move it into another more advance language?
As long as it can get the job done efficiently, and someone is willing to pay me to do it, I don't give a damn whether Java or any other language is considered "cool".
The nature of the project I'm working on and the IDE I use have far more of an impact on how much I enjoy programming than the language I'm coding in. I usually enjoy coding in Java much more than in VB not because Java is superior, but because Intellij Idea is much more pleasant to use than Visual Studio.
The equality operator should work on dereferenced objects. If there is a need in Java to compare pointers then some sort of IsTheVerySameThing() function could be applied.
The C/C++ derefernce example does not apply. One has a choice when creating objects/structs in C/C++. These objects can be stack variables or heap variables. This makes it more important to specifically require a dereference operator. In Java objects are created on the heap. period. There is no pointer syntax, no dereferencing, no etc... So, the equlity operator should be used as a logical compare not a pointer compare.
Why did all the great artists do small scale sketches of paintings before starting work on the actual painting?
The quality of a finished app that has been prototyped first, is inevitably higher, and the total development time may well be shorter, because you learn about the problem properly before you settle on an approach to program architecture and data structures. "Write one to throw away" has been suggested in many programming methodologies since "Mythical Man Month". Why not do the prototype in Java? We're back to the issue that you'll hack together a prototype much faster in Python than Java.
BTW, thanks for this little exchange, I'm sure no one else is reading it, but it's helping to put my thoughts on the matter in order.
I think you should search the slashdot history for benchmarks. Java is not slower in terms of processing, it's even faster in some cases. The only thing is that the virtual machine has to load first and it does consume a lot of memory.
Qui ne va pas à la chasse n'a pas de gibier
PHP Queb
Azureus uses SWT though, not Swing.
What are you doing with pointers that you don't have to spend any time at all debugging them?
I just follow some common sense defensive programming rules:
- always initialize new pointers
- always check the value of pointers given as arguments
- always check that pointer arithmetic is safe before attempting it
- always check return values before using them
- always fix compiler warnings
- always name functions so that there is no possible confusion about what it returns
But most importantly, once I've determined that a design is too complicated
or too confusing, I take a step back and redesign it rather than just slugging
through it to the end.
*sigh* back to work...
And from every admin and user I've worked with and asked, they hate it. Slow, slow, slow, and doesn't respond like they expect. Just because IBM manages to bamboozel some high level execs, doesn't mean it's a good product.
Java is an evolution of the static programming model also embodied by C++. Java's most important fundamental improvement over C++ is memory management. (I'm going to ignore all the flames about insert-your-favorite-Java-feature here- my point is about *fundamental* advances not incremental ones.) My experience is that this roughly doubles the productivity of a Java team over a C++ team.
Java is uncool for the same reason that C++ is uncool. It doesn't anticipate the way you think about your problem domain, and it doesn't get out of your way. This is both good and bad. By forcing you to be explicit about failure modes and method signatures, both languages facilitate programming by large teams. (This is a feature that is not shared by C, which is arguably "cool" for other reasons.)
Java is also uncool because its syntax is ugly (but not nearly as bad as Perl.), and really prolix. But the prolixity is a by-product of its static checking of your code.
The dynamic languages (Python) and the *really* dynamic languages (Ruby) are far more "cool" because they have a magical way of getting out of your way. They do this by not sweating the details about how you call your methods and raise your exceptions until runtime. That gets to be a problem in a large team when not every developer has the same intuitions about what is to be done, or over time, when your own intuitions change.
Which is better? No obvious answer, but my bias is toward the dynamic side, favoring small teams and tight, relatively short-lived projects. That's where the economic value is.
1. They do, it's called IOException. 2. Not sure why that would matter, for dev, the Java compiler and JVM should be the only things touching the files. For running a program, they should all be in a .jar, anyway.
3. Java's standard class libary doesn't use Hungarian Notation, so I don't know what you're talking about.
Centralization breaks the internet.
While the last really is a benefit java posesses the other two aren't that relevant.
True. The grandparent post, however, was saying that an interpreted language must be slower than native code. This was the point I was trying to show was wrong - Java isn't the "prime example" of interpreted code, in my opinion. I actually think the Transmeta processors are much better examples, and I think we would all realize this if Transmeta had the money to make a true performance processor.
If you realize that interpreted code, emulation, and whatever you want to call the "RISC-in-CISC" design of modern processors are all the same thing, then the statement I was making - that those can be faster than native code.
It all comes back to the halting problem, and Wikipedia has a great point here: imagine the following algorithm -
int main(void)
{
BigInt i, j, k;
for(i=j=k=1;--j||k;k=j?i%j?k:k-j:(j=i+=2));
return 0;
}
which looks for an odd perfect number, none of which are known to exist, but math has no idea whether or not they fundamentally do exist.
So there's no way the compiler can figure out that the comparison to stop the for loop may never come, but an interpreted language can notice that the likelihood of this branch ever being taken is virtually zero. There's in fact probably a formula for when the JIT compiler should start saying 'this branch will never happen - and if it does, the performance gains that come from assuming that it never happens will outweight the penalty for when it does'. Ballparking it, I can't imagine that it would take more than a hundred loops or so.
This is a bit of a poor example for an interpreted language, because there's not really any optimization that can be done here except branch prediction always assuming that the branch is not taken - although the JIT compiler could add the 'hint' to the hardware branch predictor of 'just ignore this branch' after it becomes obvious that the branch is never taken.
But you can imagine situations where an interpreted language could excel, especially given the relative "plateaus" of performance that modern PC's have:
registers>>L1-cache>>L2-cache>>main-memory>>har
If an interpreted language can shift a program from main-memory bound to L2-cache bound, it can improve the performance massively.
In particular Java is going to be slow because most JIT or interpreters I know of don't seem to remember things from one instance to the next
Which baffled me, especially considering that, for instance, the Sun JVM on Windows stays resident after loading for the first time. Completely bizarre. Apparently the Sun JVM is very good at optimizing for lots of branches and jumps, though - hence the reason that the simple "nested loops" example that I linked to performed so well in Java, even compared to the Intel compiler.
In essence, the interpreter should at the very *least* act like a gigantic BHT (branch history table) for the processor, and expect code segments to act exactly the same the next time they're run, or at least identify segments that run identically, and feed the processor "very-likely/very-not-likely" hints. Given the performance penalty for branch mispredicts, this could have a serious performance boost, especially on long-pipeline processors like the P4.
Seems you have not YET worked on Java on the server-side. Have you tried out building webserver/server based applications in Java and C++ (CGI, DCOM)? I have 6+ years of developing Java apps and managing IN production WAS4.0 servers in Solaris 8.0 and NT 4.0. It is not just about speed: it is about simplicity, elegance, and ease of deployment. Before you post someone's else comments make sure YOU have personal experience in them to validate if they are true. Java based web applications are MUCH faster than CGI or ASP stuff. I do agree Java AWT/Swing sucks. But that is a different matter since very less people use that.
"Doing what i can, with what i have." ~ Burt Gummer
I used to race little 16' boats. There was no preparing to come-about or jibe. It was just "DUCK!!" ;)
"Avoid employing unlucky people - throw half of the pile of CVs in the bin without reading them." -- David Brent
I'm still trying to work out my $LD_LIBRARY_PATH!
"Avoid employing unlucky people - throw half of the pile of CVs in the bin without reading them." -- David Brent
"MoneyDance and pdf-Office are two I know of. Its hard telling since no one generally advertises what they made their product with. Whens the last time you picked something up at Best Buy that stated it was written in C++?"
.NET most certainly DOES NOT spawn another "VM" to run a 2nd .NET application. Remember that .NET isn't "exactly" a VM, moreso an "Application Framework". You better do some reading.
A) Oh Yeah ? You find it in the product catalog.
B) They don't have to, most commercial product out there have been written in a combination of C/C++/VB and when necessary, some scripting language. Java, has yet to be ( and will continue to not be ) accepted as an acceptable platform for commercial applications because the benefits it provides for the "Enterprise" aren't the same set of goals necessary for commercial success of a on-the-shelf product. Neither of those show up at BestBuy/CompUsa or Office Depot/OfficeMax...Where exactly did you say you could buy them off the shelf ? Oh, that's right, you didn't.
How many have on-the-shelf products have you done ? I have several ranging from programmable mice ( InterAct(R) Programmable Wireless Mouse ), to software used to produce some of the very commercials your TV is playing in the background, while you're on the eating your cheese doodles. The goals and needs of software that GrandPa Joe, and Auntie Sue would need to use, just AREN'T capable of being MET, by JAVA....at least not yet. How come we never hear about any usability studies done on Java desktop software.....that's because there aren't that many, and those that are, are VERY VERY vertical in nature.
"if you look hard enough kid."
I've been in this industry 20 years, and programming long before that....whippersnapper. And for that matter, sure, a direct link would've been better, but do some research....like I have. But then again, I'm not here to disprove your point, you're here to prove yours. Oh that's right, you didn't post a link to where to buy MoneyDance. Awww.
".NET does not have a multi-app virtual machine."
Au Contraire Mon Frere....
Of course a Mod has to set this as "Troll"...because of course that person has no answer to the question put before them ? I had mod points when this topic came up, rather than Mod this thread, I chose to contribute by posting my opinion, and of course, because someone didn't like it, and yet couldn't offer any substantive rebuttal, Modding me Troll was of course, the "adult" thing to do.
Suits me just fine....You don't like what I have to say....no problem, it doesn't change that I'm still right. Like some skiff boat captains.....
The idea that your code is so tough to manipulate that you need an IDE to make it viable should say somethign to you about the language in question. When we talk about the future of coding and machine-assisted development, I don't think this is the vision we want to see.
Refactoring Java code can be very tedious, especially if you chage a type that goes into a collection. Even with the new Java Generics, this is going to be a huge pain. In Python or Ruby or Lisp, it's transparent. Heck, even in modern statically typed languages like Haskell and OCaml, it tends to be almost transparent.
Java's manifest typing model is outdated and cumbersome. This fundamental feature of the language lends itself to every aspect of work within. The Libraries may employ some great OO patterns, but they still can't escape the fundamental... well... clumsiness of the language.
As for the next argument against Java? Why doesn't Sun trust developers? Sun feels it's okay to use operator overloading on strings, why can't I use it for my complex number class?
The argument that "you might abuse it" is a lame argument at best. Bad programmers shouldn't program professionally. Do you let a bad basketball player stay on a pro team? Do you let a bad accountant manage your money? Do you let a bad contractor build you a crappy house? Do you let a bad manager control the fate of, um, your... company?
The only reason I can see for this attitude is that Java wants to bring bad programmers into the fold. Why? Well... let's put on our cynical tin-foil hats and theorize for a second?
Forgive me if I think someone is trying to screw over real software talent by commoditizing it. The sad thing about it is that this makes the consumer the ultimate victim, since they rely on poorly-made software.
And before you say, "That's just conspiracy theory" consider how much money there is in the software market, and how many people there are who have no fscking clue about what goes into good software making decisions on how it will be made.
Hanlon's razor could probably account for it just as well as my little tinfoil pirate hat.
Slashdot. It's Not For Common Sense
That's six "always" conditions. From a reliability point of view, "always check" isn't very reliable. You're advocating a system that relies and requires inspection (check this, check that) to achieve quality. That is a well known anti-pattern in quality engineering.
To people who choose not to use a gui based desktop at all, I say get a life and at least update your tech skills to 1980. I'm a CLI lover, but if you don't ever use a windows environment by choice I can safely say your behavior is so outside the mainstream to sustain my "you baffle me" comment.
As to files on machines that don't have a GUI, fine. I edit such files using jEdit. If the file is on a machine that I can access via the network, then I can edit the files there via jEdit (using the FTP/SFTP plugin). For example, I have a linux firewall with no GUI (and no monitor). When I need to edit files on it, I use jEdit from my PC to edit those files in place via sftp. If the box doesn't have networking, I wouldn't use it to edit files at all (since I would have to create every character by hand every time). Instead I would create it on a machine with jEdit and transfer it using disk, CD, or RS-232 as needed. If we are talking about writing code, this is ESPECIALLY important, since I will probably be reproducing that code on multiple machines and so from a configuration management point of view I want not to have data islands.
So why not write my whole app in shell scripts, then?
I mean seriously, this is probably the worst example I've seen of Java's so-called "portability". Java's proponents rant about how "Java is so cool because it removes the #ifdefs of C and C++..." and then go on to further complicate the issue with CLASSPATH - which requires a different configuration for each architecture. So, I guess if you really hate the word "ifdef", Java must seem a godsend. But it doesn't qualify for the holy grail of "write once, run anywhere..." Basically, its a stripped-down, slower C++.
I do write in Java. But I realize that it isn't good for anything but internal development:
Sorry to rain on your parade, but Java isn't the be-all, end-all of languages. It's okay for a narrow range of applications, but not good at anything, unless you count teaching CS.
The society for a thought-free internet welcomes you.
10 seconds worth of preventative measures to prevent time-consuming debugging
at a later time seems like a bargain to me. What's the problem?
Anyhow, I'm not advocating any system. I was asked how it was that I didn't
have to spend time debugging pointer problems and I explained what steps I
took to prevent pointer problems in my code. These are all steps that a
good defensive coder (i.e. one who actively takes steps to prevent common
errors) is going to take regardless of what "system" (s)he uses.
*sigh* back to work...
I think that shows what /. shows - the Linux community is hostile to Java. The claim was that there was no free software in java - that has been utterly refuted.
The fact that linux distributions don't use much Java is a reflection on Linux distributions, not Java or Java developers.
If X is the new Y, and Y is "X is the new Y", solve for X.
If X is the new Y, and Y is "X is the new Y", solve for X.
*cough* ... and didn't learn the lesson when IBM wanted to talk to him.
If X is the new Y, and Y is "X is the new Y", solve for X.
Ever heard of C or C++? Ever heard of a little group of companies which used to be AT&T? Is 99.999% uptime and 99.9% call completion "Enterprise Class" enough for you? That's right, phone switches are software. Mostly written in C.
I think that shows what /. shows - the Linux community is hostile to Java. The claim was that there was no free software in java - that has been utterly refuted.
I think it's caused by three things. One, that both RedHat and Debian care about really free software, software that doesn't depend on non-free software, and Java doesn't have much of that. Two, all the old mature software--GCC, libc, Linux, emacs--predates Java. Three, and this is less obvious and more argumentative, there's a big difference between the software in Sourceforge and Freshmeat and software that someone actually cares to package for a Linux distribution. There's not a whole lot of important software in Java, IMO, which may be due in part to the fact that important software takes a while to mature.
I'd mod your post Interesting, but I'd rather reply...
It's true that many people miss the point of JIT in Java and make poorly justified claims that C and/or C++ will always be faster. However, it's equally true that many Java fans make a similar mistake, in assuming JIT to be a silver bullet.
I'll begin, if I may, with a selection of excerpts from your post that I believe capture your argument.
The first problem with this is limited potential. As we all remember from the first time we coded a bad algorithm, the little adjustments really don't make that much difference to performance once you've reached "good enough"; algorithmic complexity is usually what matters in the grand scheme of things, and while micro-optimisations help, you get diminishing returns.
Now, C compilers have 20+ years of experience with things like loop unrolling, eliminating common subexpressions, yada yada. C++ compilers have a somewhat harder job because the language is more complicated, but are rapidly catching up. Java's been way behind the pace for years, and JIT allows it to level the playing field somewhat, since it's finally running as a compiled rather than an interpreted language. It's important to realise that it doesn't do much more than that, however; it hasn't invented a dozen magic new optimisations that were unknown to the C compiler community before. Which brings me to the other flaw in the usual "JIT will be faster" argument...
That other flaw is that all this run-time optimisation is not free. Sure, you could just use a straightforward compile-on-load process, optimised for the particular platform in use, and you'd get similar performance to a C application compiled to target that platform once you were past that oh-so-annoying start-up lag (at least the first time). But to do the clever run-time stuff, the stuff you describe, requires actively monitoring the running code, and doing that is expensive.
To get an idea of just how expensive, consider the type of instrumented executable often used for profiling with C or C++. These can run an order of magnitude or more slower than a fully optimised version. If you want the kind of run-time customised optimisation you're talking about, you're going to take a huge hit in the monitoring code. Moreover, if you turn the monitoring code off after you've done the optimisation, you're going to be screwed if the data within your application changes significantly, so you'd have to leave some basic monitoring on even in the optimised version.
Now, if you're talking about an application that runs the same few subroutines thousands of times on similar data, it might be worth the overhead, but for most code, that simply isn't the case. The impact of the monitoring and recompiling/optimisation overheads will always limit the effectiveness of any JIT optimisation process, and since we're talking about diminishing returns micro-optimisations anyway, you're simply never likely to beat AOT-compiled C or C++ code of a similar quality just because of a JIT optimiser.
So, the bottom line(s):
If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
I agree with a lot of your points about bias, but this one irritated the hell out of me, I'm afraid. Although the people you mention may have popularised the terms you mention, the actual ideas behind them have been around for far longer, and used in many languages before Java. The latter simply makes a convenient buzzword to which other convenient buzzwords (like, say, "patterns" or "extreme programming") can be attached for the purposes of impressing PHBs and students.
If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
In dynamic logic, formulas are interpreted as state transition functions.
Are you adequate?
...directed at "Enterprise-grade apps and "coolness" may be inapproriate bedfellows.
Besides, does any language offer both?", from the original post.
I get very annoyed about the whole "C verses Java" business, and even more annoyed at the term "C/C++". They're not the same language, damnit!.
C++ lets you do what you like, and as much of it as you like. C forces you to do everything, and Java stands over you with a whip from the first line. Out of those, give me "do what you like" anyday. C++ allows far greater range of expression than C or Java. You can build powerful types that behave as if they were part of the language to begin with, and won't break if you accidentally trip over the wrong global or cast them the wrong way. If you want OO, you can use as much as you like without having to pay for any more. If you want compile-time type safety for you custom types, you can have that too.
And for God's sake, if a text editor can have exception handling, surely it's not too much to ask for?
C is ancient and crude. Java is a padded cell and straight-jacket. There is a middle ground.
programming languages are usually specific to a problem domain, where they should stay. i'll grant you that it's possible to write webapps with C, but I'd just love to watch you sit at it and curse. or is that ncurse for the C-fetishists??? :-)
i won't. all my C programs are so fast already, if i upgrade gcc, all i'll be able to see is the vapor trail in my syslog. and since i'm apparently not very cool, i like to sip hot coffee and actually watch what the application is doing ;-)
let others read the realtime matrix
Thank you for commenting!
I agree with much of what you wrote, I realise that I in fact did overplay the significance of JIT having runtime knowledge. I wanted to stress the fact that Java isn't simply an interpreted language, not even when you use the JVM from Sun.
The most important point of my post, though, is that "Java isn't slow" anymore. When I first got to know Java, it was dreadful slow. Now, its comparable to C++, and in some cases even faster, and has the potential to be even faster. Now, all this fuss about performance has really nothing to do with the Java-language, but has to do with the Java-platform, its not unrealistic to write a compiler for C that generates Java-bytecode for the Java-platform, but the point is that the Java-platform today proves that it does in fact work, that it doesn't slow performance, as seen in early stages. It has its strengths and weaknesses. One point I must make though, is that in my opinion, JIT is not the single key that Java has reached the performance of C++. Of course, JIT _does_ help a lot, esp. in CPU intensive code, but there are other factors as well. One really important point, is that Java Bytecode applications can allocate memory very cheap, as explained in my previous post.
That being said, lets discuss JIT a little...
(Just for the record):
Its naive to assume that the cost of JIT is free, but its also naive to assume that Java compilers would not benefit from the last 20 years of experience on C compilers. The Java compiler from SUN is able to optimise the bytecode as well AOT as well as optimise the bytecode with JIT.
Your analysis on when JIT is beneficial, is very good, I do have a few notes though:
I don't think that this pose a real problem. The point is that "Most code", doesn't need much CPU, and thus the overhead of the JIT profiling, won't matter much, whereas the bonus from JIT-compiling critical code in CPU-intensive code will be a great gain for the JVM.
In C, when you write CPU-intensive code, you usually hint the compiler about optimising, in one way or another, since you know which code you want to be optimised. You may "inline" some code, ask to get an index variable kept in a register, and compile with flags / options like "-funroll-all-loops", "-funsafe-math-optimizations" and others. Usually, these hints will make the compiler able to make as good decisions as any JIT would be able to.
On the other hand, if you write CPU-intensive code, without paying attention to micro-optimising, chances are that the JIT-enabled code will run slightly faster (given the same algorithm, of course). With todays speed of CPU's, Code that is not CPU-intensive, will often seem to run at equal speed, from the users perspective, whether its interpreted or (JIT)compiled. (Even though they might actually be faster in the AOT code).
Here is an example where the JIT compiler seems to slow down the code, and how to mend that. Note that this type of code is very rarely seen in actual real life programs.
If we talk about really micro optimising code, I guess you would want to either write the code in assembler, or be really creative about how you optimise your code. As I mentioned in my first post on this subject, Java can also be compiled with AOT compiles! Another possibility, if you know that C is faster (or already have the optimised code in C source), is to use JNI (Java Native Interface), that lets you call native code. Note that this will of course invalidate any claim as to be "Pure Java" code.
Sorry, when trying to preview the unfinished post, I hit submit by mistake. I hope the post still makes sense, it was almost done, but I like to read what I post a few times, before I post, just to make sure its how I want it to be.
/Spam .
It's pretty dull stuff, and that dullness has shaped how the language of choice is perceived. While Java jobs may outnumber C/C++ jobs a bit, I'm betting that once you limit the field to jobs that offer real technical challenges (i.e. the hardest part isn't figuring out what the PHBs want) or that otherwise involve doing something really novel with software, Java doesn't look nearly so hot.
"Technical challenge" is a little fuzzily defined here. If biz apps were "simple" or "easy" then it would all come in an off-the-shelf box. The trick is to automate and abstract the allegedly boring repetative stuff so that you don't have to keep doing it over and over. This is the same in any domain, not just business. I also notice "scientific applications" sometimes spend a lot of code reinventing stuff that a good database would make a snap. Personally, I think reinventing tools that already exist is kind of boring.
Anyhow, what is an example of an "exciting application" or domain from your perspective, and why?
Table-ized A.I.
I think the important thing in terms of large (or even not so large) development teams is to have a strong underlying design, and development leads who make sure it's maintained and doesn't decay into special cases over time. OO can be a useful strategy for achieving this, but certainly isn't the only one. You can achieve just the same effect with procedural or functional programming, for example, or any combination of the three ideas, provided that all the developers have a basic understanding of the design and the leads are there to back them up.
BTW, I went through college when Java was being forced into the mainstream as well, but I'd still rather work in a language where the concept of null pointer exceptions simply isn't necessary. :-)
If you disagree, post your argument. (-1, Overrated) isn't your personal censorship tool for views you don't like.
Comment removed based on user account deletion
OTOH, you just found time to tell us about a cool app that's not cool because of its Java source language - it could have been written in Flash, or even a dedicated app for Windows/Mac/Linux. The "coolness" we're talking about is the Java language itself, and its dedicated tools, not the GUI or any features of the apps written in Java. Only if those were unique to Java would they make Java cool. How about the namespace management tools, threading model, libraries? I always thought the networked classloader was extremely cool, combined with the safe sandbox I'd expect to see a lot more "mobile network agents" running in Java VM application servers by now. Next time you take a break from the big money gigs to wax enthusiastic about Java, how about clueing us in to how cool Java actually does make your job. Fortran also works, but it's not as cool as Java.
--
make install -not war
or the article : Discovery Of Three Headed Frog Increases Demand For 3 Headed Pets - March 7th 2004 http://www.randomperspective.com/page.asp?1news/2
Back on-topic: The real reason C programmers don't like java is because it is wayToVerboseAndYouHaveToTypeALotToGetAnythingDone.
We respect the Kung Foo of our enemies, especially when it is strong.
LK
"Hi. This is my friend, Jack Shit, and you don't know him." - Lord Kano
let me second that:
ha ha ha
(im actually a java AND c++ developer)
NO!
lets face it, for the sysadm crowd of
i dont say that to start a flame war, its just that not all software in the planet are designed to show some crappy web page or extract some crappy data from some simple odbc link....
the way i see it, you must have programmed assembler and C in complex projects to count as a real programmer. if you dont belive me, check the nearest job database