Posts: 1,752
Threads: 21
Joined: Jun 2002
Quote:Plasma Wrote:It's slow,
In exchange, it's platform independent (well, not quite as the java developers wanted, but it's much better than other languages)
So being platform independent is an excuse for being slow?
Quote:Plasma Wrote:it's bloated
How? (Honest question, not an argumentative statement).
The JRE for Windows is 14+ MB.
Quote:Plasma Wrote:and it doesn't even truly compile.
Course it doesn't. That's the whole point of it...
Are you aware that Java bytecode can be decompiled into the original source, complete with the original variable names? No problem for hobbyists, but a big problem if you're trying to sell something.
Quote:Plasma Wrote:On top of that, Java forces you to use classes all the time, even when they're unnecessary.
Plenty of other languages force code upon you that is unnessecary. Here's a simple program in java:
Code: import javax.swing.JOptionPane;
public class Foo {
public static void main(String[] args) {
String input = JOptionPane.showInputDialog("Enter a number");
n1 = Integer.parseInt(input);
input = JOptionPane.showInputDialog("Enter another number");
n2 = Integer.parseInt(input);
double s, d, p, q;
s = n1 + n2;
d = n1 - n2;
p = n1 * n2;
q = n1 / n2;
String msg = "Sum is " + s + "\n" +
"Difference is " + d + "\n" +
"Product is " + p + "\n" +
"Quotient is " + q;
JOptionPane.showMessageDialog(null, msg);
System.exit(0);
}
}
One class, one method. In fact, it's really just like a QB program, except with java syntax. I imported the JOptionPane class for fun. If you ignore the obvious stuff (public class, public static void main) then it's just procedural code. You don't have to use classes at all, that's just a convention.
Er...One could say any language is really just like QB with a different syntax.
Quote:In fact, I could emulate the way qb codes, by making all methods inside the class and staticing them.
So when are you forced to use classes, other than the first one? You can program like QB if you want, just classes are a better way of doing it IMHO.
Try making a GUI with multiple JPanels using only one class.
Posts: 4,307
Threads: 63
Joined: May 2003
Dude, we have had countless arguments over this!!!
Java is an interpreted language and *not* a compiled one. So it is bound to be slower than C/C++ or any other compiled language.
Secondly, Java stands up quite well to C++ in terms of execution speed.
My above statements doesnt mean that I am supporting Java, but those are facts. Infact I think it is bloated, confusing, illogical, dumb, foolish and completely useless language(well ok, not completely).
Posts: 3,343
Threads: 83
Joined: Mar 2003
Quote:So being platform independent is an excuse for being slow?
Nope, but is being fast an excuse for not being platform independent?
Quote:The JRE for Windows is 14+ MB.
Big wup. The .class files are the ones I'd be worrying about, and normally (for small programs) they're smaller than the source.
Quote:Are you aware that Java bytecode can be decompiled into the original source, complete with the original variable names? No problem for hobbyists, but a big problem if you're trying to sell something.
I'm sure that problem is work-aroundable or something, because it doesn't seem to have stopped many programmers around the world using it...
Quote:Er...One could say any language is really just like QB with a different syntax.
True. But what I'm saying is that although we're taught to code with classes etc, we can still code using static methods and using them as subroutines, a la qb.
Quote:Try making a GUI with multiple JPanels using only one class.
Try making a gui with multiple windows in QB, using only one module. That's not a hinderance, that's a help.
Posts: 3,368
Threads: 195
Joined: Jan 2003
Quote:Programming languages and indeed computers were designed by dark, twisted geniuses. They must have been. I'm not dark, twisted or a genius. But there's some kind of lure in their twisted constructs... I wonder why normal people (like (I hope), me and the average guy down the street even TRY to understand computers, computing, programming and the way these freaks thought?
Apologies in advance to any dark, twisted genius freaks out there.
Indeed.
* Shoots Java. Three times. *
Peace cannot be obtained without war. Why? If there is already peace, it is unnecessary for war. If there is no peace, there is already war."
Visit www.neobasic.net to see rubbish in all its finest.
Posts: 222
Threads: 23
Joined: May 2003
What I was thinking of was C's struct handling, I've never tried Java-- though I guess it's just a fancier C++?
In a race between a rock and a pig, don't varnish your clams." -- "Dilbert"
Posts: 6,419
Threads: 74
Joined: Mar 2002
No, it is a true OO language. More close to C#.
Posts: 4,307
Threads: 63
Joined: May 2003
Why, why, why cant we just *stop* squabbling over Java/C/C++?
Posts: 222
Threads: 23
Joined: May 2003
Hey, I was just asking.
In a race between a rock and a pig, don't varnish your clams." -- "Dilbert"
Posts: 6,419
Threads: 74
Joined: Mar 2002
Quote:Why, why, why cant we just *stop* squabbling over Java/C/C++?
Because it's fun
It is like fighting with rubber bats, you don't get anywhere but you get tons of fun :lol:
Posts: 222
Threads: 23
Joined: May 2003
Hang on, hang on. I think people got the wrong idea about what I was asking. I was asking a genuine question. I got an answer which was fairly informational. My question was a question, NOT inflammatory rhetoric. I don't really have too much opinion when it comes to programming languages. Use what you want. I can't stop you.
In a race between a rock and a pig, don't varnish your clams." -- "Dilbert"
|