On Java and C++

W

wellstone9912

Java programmers seem to always be whining about how confusing and
overly complex C++ appears to them. I would like to introduce an
explanation for this. Is it possible that Java programmers simply
aren't smart enough to understand C++?

This is not merely a whimsical hypothesis. Given my experience with
Java programmers --- the code they write and the conversations they
have --- Occam's Razor points to this explanation. For example,

"Oooh I'm confused about the difference between pointers, references,
and objects! How confusing!"

"Oooh operator overloading confuses me! The expression x + y is so
confusing, who knows what's happening with that? If x and y are
complex numbers, what the hell could x + y mean?"

"Oooh multiple inheritance is so confusing! Though I am both a father
and a programmer, I still find it so confusing how the same object can
be two different things! How confusing!"

"Oooh and virtual bases are so bizarre! I am a student --- myself
'the father' is the same student as myself 'the programmer' --- but
nonetheless the idea of virtual bases is absolutely confounding and
confusing to me!"

Again, Occam's Razor is a valuable tool here. In deciding among
competing hypotheses, choose the simplest one. To impartial observers
of indoctrinated Java programmers, the explanation is simple indeed.
 
A

Andrew McDonagh

(e-mail address removed) wrote:

snipped dribble....

oh good a pissing competition!

My Ruby is better than your (Insert your fave, all time language here).
 
?

=?ISO-8859-15?Q?Juli=E1n?= Albo

Again, Occam's Razor is a valuable tool here. In deciding among
competing hypotheses, choose the simplest one.

The simplest is: you are a troll.
 
I

Ian Collins

(e-mail address removed) wrote:

drivel

+-------------------+ .:\:\:/:/:.
| PLEASE DO NOT F :.:\:\:/:/:.:
| FEED THE TROLLS | :=.' - - '.=:
| | '=(\ 9 9 /)='
| Thank you, | ( (_) )
| Management | /`-vvv-'\
+-------------------+ / \
| | @@@ / /|,,,,,|\ \
| | @@@ /_// /^\ \\_\
@x@@x@ | | |/ WW( ( ) )WW
\||||/ | | \| __\,,\ /,,/__
\||/ | | | jgs (______Y______)
/\/\/\/\/\/\/\/\//\/\\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
==============================================================
 
N

Noah Roberts

Ian said:
(e-mail address removed) wrote:

drivel

+-------------------+ .:\:\:/:/:.
| PLEASE DO NOT F :.:\:\:/:/:.:
| FEED THE TROLLS | :=.' - - '.=:
| | '=(\ 9 9 /)='
| Thank you, | ( (_) )
| Management | /`-vvv-'\
+-------------------+ / \
| | @@@ / /|,,,,,|\ \
| | @@@ /_// /^\ \\_\
@x@@x@ | | |/ WW( ( ) )WW
\||||/ | | \| __\,,\ /,,/__
\||/ | | | jgs (______Y______)
/\/\/\/\/\/\/\/\//\/\\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
==============================================================

Wow, posted for only 15 minutes and already 3 replies including a
"don't reply to the trolls" reply.

Nice one ;)
 
M

Monique Y. Mudama

["Followup-To:" header set to comp.lang.java.programmer.] On
2006-04-26, (e-mail address removed) penned:
Java programmers seem to always be whining about how confusing and
overly complex C++ appears to them.

No, they aren't.

Therefore the rest of your troll is moot.
 
M

Mishagam

I agree that may be C++ programmers are smarter. Even more, I agree that
person that fully understands C++ (or Common Lisp, or PL/I) should be
very clever and more clever than average (not neccessary Java) programmer.
But this doesn't help C++ to be very bad and getting steadily worse
language.
Because computer language is tool. Because people don't study language
for the sake of it, they study them to write programs. More difficult
and complex language is, more time is wasted studying it, and less
people will understand what they are actually writing when they use this
language. I bet <1% of C++ programmers fully understand C++ language. I
am sure statistics is radically different for Java - which is MUCH
simpler and more easy to understand. I myself programmed about 10 years
on C++ and 5 years on Java, so I was able to compare them.
And I am sorry for people who achieved full understanding of C++ virtual
inheritance, STL, Templates, Functors, and so on. They uselessly wasted
huge efforts.
And writing programs on complex, poorly understood language doesn't help
to write reliable and efficient programs.
In this sense C was much better language (through clever use of
preprocessor could provide ugly programs). And I understand why C is
still so popular in Linux.
 
L

Luc The Perverse

Java programmers seem to always be whining about how confusing and
overly complex C++ appears to them. I would like to introduce an
*snip*

LOL - welcome troll!
 
G

Gernot Frisch

....
In this sense C was much better language (through clever use of
preprocessor could provide ugly programs). And I understand why C is
still so popular in Linux.
....

Now, you are begging for a fight?
 
A

al pacino

i am a student,
and i have seen many of my friends 'switch' over to java cos they shy
away from learning much involved language c++
and also they seem to like things like easy GUI interfacing than actual
programming (like practising data structures ..b trees et al.)
 
M

Mishagam

Gernot said:
...
...

Now, you are begging for a fight?
How should I respond to this? May be I am new to this newsgroup.
I (esthetically) liked C very much when I have first seen it, and still
think it is (and especially was (I mean in context of 70-80s when it was
created)) very good language.
However I now prefer to program on Java. I think best quality of Java is
how beautifully it removes most unnecessary choices, leaving one very
decent way to do things.
I now (esthetically) hate C++, however still program on it (using very
few 'modern' features, but using classes) sometimes.
So I stay by my opinion that C is (was) good language, and C++ is bad
language.
 
L

Luc The Perverse

al pacino said:
i am a student,
and i have seen many of my friends 'switch' over to java cos they shy
away from learning much involved language c++
and also they seem to like things like easy GUI interfacing than actual
programming (like practising data structures ..b trees et al.)

Learning C++ is marginally more difficult than learning Java.

I used to be a die hard C++ advocate - but the added complexity doesn't
really add a great deal of usability; but it is great for obscuring the
meaning of the code.

Java is simpler, cleaner - but programming is programming. Java is
designed to be able to more easily make integrated GUI apps. This might,
in turn, make the code of two programmers with otherwise equal talent, one
in C++ and one in Java, differ and their end results differ. In C++ you
have to reinvent the wheel all the time. Except, it's not like you're
rediscovering, just annoyingly doing the same thing repetitively to take up
more time. In Java you implement one of the provided algorithms, and you
are good to go, with an exponentially smaller possibility that the
underlying algorithm code is in some way flawed. (With as many Java users
as are out there, a bug should pop up pretty quick.) GUIs are easier, in
general, so the java programmer can use that time to make their GUI better.
Web examples (sample code) tend to work, unlike C++ where if you download
something, there is only a miniscule chance that it will compile after 20-30
minutes of fiddling.

Blah - I'm just blabbering. My point is that coding in Java saves times,
and lessens bugs. It will make the end result better. All the bad things
I thought of Java are pretty much gone.

The reason I am replying is you just seem to have contempt. "Actual
Programming" problems will arise, they will just be less mundane.

I think you might be confusing Java with VB.

Trust me though - you can practice algorithms and data structures in Java -
I do so at least 3 times a week on topcoder.
 
G

Gernot Frisch

How should I respond to this? May be I am new to this newsgroup.
I (esthetically) liked C very much when I have first seen it, and
still think it is (and especially was (I mean in context of 70-80s
when it was created)) very good language.
However I now prefer to program on Java. I think best quality of
Java is how beautifully it removes most unnecessary choices, leaving
one very decent way to do things.
I now (esthetically) hate C++, however still program on it (using
very few 'modern' features, but using classes) sometimes.
So I stay by my opinion that C is (was) good language, and C++ is
bad language.

The so called "ugly" features is what makes C++ so powerfull. Operator
overloading is essentiall for RAD-classes. Aynway...
 
B

benben

Learning C++ is marginally more difficult than learning Java.

I hate feeding trolls but it is just unfair for C++...

I learned Javascript before C++. My impression is even though C++ is
noticeably more complex, it is not more difficult to learn than Javascript.
I used to be a die hard C++ advocate - but the added complexity doesn't
really add a great deal of usability; but it is great for obscuring the
meaning of the code.

A screw driver can help you fix your car; yet it can also do damage to
your car depending on how you use it. C++ is no different. It is just a
tool after all, and you CAN definitely obscure the code with C++. It
takes experience and skill to write good quality code in just about any
language.

The added complexity to C++ is a result of meeting the need of a wide
range of audiences. The language is like a big toolbox, and it is just
unfair to blame the toolbox for offering much more than what you need
for your task.
Java is simpler, cleaner - but programming is programming. Java is
designed to be able to more easily make integrated GUI apps. This might,
in turn, make the code of two programmers with otherwise equal talent, one
in C++ and one in Java, differ and their end results differ. In C++ you
have to reinvent the wheel all the time. Except, it's not like you're
rediscovering, just annoyingly doing the same thing repetitively to take up
more time. In Java you implement one of the provided algorithms, and you
are good to go, with an exponentially smaller possibility that the
underlying algorithm code is in some way flawed. (With as many Java users
as are out there, a bug should pop up pretty quick.) GUIs are easier, in
general, so the java programmer can use that time to make their GUI better.
Web examples (sample code) tend to work, unlike C++ where if you download
something, there is only a miniscule chance that it will compile after 20-30
minutes of fiddling.

It is again an unfair comparison. The ease building GUI apps with Java
has nothing much to do with the simplistic design of the Java language.
It is Java's "standard" class libraries that allows you to program Java
from a higher level than system calls.

You can program C++ GUI at the same level. First thing to do is to find
a library that supports you. These good libraries are unfortunately not
part of the C++ standard and it is a shame that a lot of people are
under the impression that C++ is incapable of, or poorly supports, tasks
that requires non-standard C++ libraries.

Part of Java's popularity comes from politics rather than technicality.
But I am not in the mood of discussing politics.
Blah - I'm just blabbering. My point is that coding in Java saves times,
and lessens bugs. It will make the end result better. All the bad things
I thought of Java are pretty much gone.

Meanwhile Java is getting larger and larger.

Regards,
Ben
 
M

mishagam

Monique said:
["Followup-To:" header set to comp.lang.java.programmer.] On
2006-04-26, (e-mail address removed) penned:
Java programmers seem to always be whining about how confusing and
overly complex C++ appears to them.

No, they aren't.
They aren't because usally nobody forces them to program on C++ and
they have no reason to whine. It is C++ programmers who should whine
about this. But it appears now, when C++ became finally complex enough
to be unacessible to mere mortals, that C++ programmers are feeling
themself members of club open to introduced only . Now they look
somewhat like Linux hackers looking down on programmers using other,
less esotheric languages.
 
M

Mishagam

Monique said:
["Followup-To:" header set to comp.lang.java.programmer.] On
2006-04-26, (e-mail address removed) penned:
Java programmers seem to always be whining about how confusing and
overly complex C++ appears to them.

No, they aren't.

Java programmers have no reason to whine because usually nobody forces
than to use C++. It is C++ programmers who could whine.
But, when C++ finally become too complex to be understood by mere
mortals, C++ programmers become feeling themselves members of club with
secrets comprehensible only to introduced. They become proud to use C++
and look down on programmers using less esoteric languages like Java.
And so they don't whine either, and C++ language quietly and slowly
moves toward oblivion ;)
 
M

Mishagam

Gernot said:
The so called "ugly" features is what makes C++ so powerfull. Operator
overloading is essentiall for RAD-classes. Aynway...
I always wondered in such context what word 'powerfull' means?
Does it mean that you can write program that cannot be written on Java?
or Does it mean that you can write shorter C++ program doing the same as
equivalent Java program? Then may be you should like Perl even more?
Or does it man that you can write library, such that equivalent C++
program will LOOK simpler than Java program?
 
M

Mishagam

Mishagam said:
I always wondered in such context what word 'powerfull' means?
Does it mean that you can write program that cannot be written on Java?
or Does it mean that you can write shorter C++ program doing the same as
equivalent Java program? Then may be you should like Perl even more?
Or does it man that you can write library, such that equivalent C++
program will LOOK simpler than Java program?
I meant in last case C++ program using C++ library looks simpler than
Java program using Java library.
 
C

chris.mccreadie

I think that some people may be missing the point in having multiple
programming languages.

Why do you think that the world has more than one language? Why don't
we all use English instead of all having different languages, it would
make life so much easier. Well, in fact, it wouldn't.

In my honest opinion, once you know how to program at a decent level,
you should be able to use any language with just a small amount of
effort, if you want to master that language then fine, but be prepared
to put the work in. At the same time, the amount of programs or
applications that require a team of programmers to know every in-depth
detail of their language is slim.

C++ has advantages over Java, it also has its fair share of
disadvantages. I don't buy into the fact that Java is easier to learn.
I have been a learning C++ for about 3 years and as part of my uni
course, have now been asked to program some Java. I find Java as a
language nice to work with but have the same number of problems I would
have expected from learning a new language. Yes, its a slimmed down
version, yes it may be easier to do certain things but if we made all
programming languages insanely difficult only a small number of people
would ever get the joy the rest of us get from programming.

Just my thoughts.....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top