Thread

Programming Languages (Sdk)

Programming Languages // Sdk

1  |  

maxsilver

Feb 10, 2003, 7:06pm
Just wanted to pick up a new comp language and was wondering which of the
following is easier?

Java or C++

I already know HTML and Basic, and some VB

bowen

Feb 10, 2003, 7:32pm
[View Quote] Mmm... it's not what's easier, it's what you want to do. I would recommend C++, but
that's just me. (I think they're both... pretty good, not to mention pretty similar)

--Bowen--

grimble grimble2000@btinternet:com

Feb 10, 2003, 8:27pm
I'd say its "concept" time, rather than a new language. If you are to make
the most of either C++ or Java you'll need to get to grips with OO to a
level where C++ makes a difference (i.e. not just writing C code and using a
C++ compiler). Otherwise its just syntax and you don't learn anything new
and rewarding.

If it was a straight choice, I'd say C++ is more straight forward,
especially for a windows developer, as it without all the additional
confusion of packages, runtimes et al. Not enough "get up and go" about Java
to feel like your making that early breakthrough to keep the interest. My
gut feeling would be a bit of reading into high-level OO concepts, then C++,
then ONLY OO in C++, then Java. Java makes much more sense when you have a
solid grasp of the underlying premises, which are too different to
procedural languages to make a simple transition using typical get-stuck-in
learning methods employed by the casual programmer.

If its used right (classes, classes, classes), C++ is a very productive
language and quick to learn with the right grounding. My thoughts ... feel
free to contradict.

Grims


[View Quote]

bowen

Feb 10, 2003, 8:30pm
> If its used right (classes, classes, classes), C++ is a very productive
> language and quick to learn with the right grounding. My thoughts ... feel
> free to contradict.

Sounds good, was certainly more fun to read/listen to then my C++ teacher's 2.5 hour
lecture on ints.

--Bowen--

ananas

Feb 10, 2003, 9:10pm
Swing (the Java GUI classes) are a real pain, the C++ GUI
classes I know are easier to handle, some are available
for several platforms. Java is less portable than C++ if
you use portable C++ GUI classes, even if SUN tries to tell
us something different. Swing is extremely version dependant,
even a minor version change can make your program fail to run.

Java itself isn't a bad developement language, but only for
backend stuff. Easy to switch between C++ and Java later if
you understood the OO conzepts. The language differences are
minor. C++ is way faster, the programs are more compact and
you cannot do everything in Java that you can do in C++.

Leave the fingers away from C# though, that's plain crap. And
for both C++ or Java use Visual Age (by IBM) only if you have
good nerves.


But C/C++ and Java are sure not the only choices, coming from
VB you might like Pascal/Delphi. I do not know Delphi, just
Pascal and Turbo Pascal, and those are very well structured
languages that make it easy to learn a good style.
Not as portable as C/C++ or Java but much easier to read and
understand without taking classes.
Several bots (e.g. [Delph]) are written in Delphi, AccuTrans
is in Delphi too, so for AW it should offer everything you
need.


So if you want to get into the language fast, Delphi would be
1st choice, if you want to put some more work into learning
and program developement time is less important than program
speed, C++ is what you should try.

Java only for very specific things, web services for example,
but never for GUI programs.


Otoh.: Ask 10 program developers and you will get 10 different
answers ;)


[View Quote]

frizzlefried

Feb 17, 2003, 9:41pm
I've done commercial development in both C++ and Java, and it's true that
there really isn't much of a difference conceptually between the two.
Personally I think that C++ is an all around better language - however, that
being said, Java has many advantages, especially if you are new to
programming:

* You don't really need to worry about memory management with Java, where as
with C/C++ it's usually the thing that kills new programmers - and programs
(literally).

* There is no need to create header files or prototypes when creating an
object, so consequently is more intuitive for new developers.

* The standard libraries for Java are way more robust than the standard
libraries for C++, including classes for handling such things as XML,
regular expressions, compression, cryptography, sound, vectors, and user
interface, to name a few.

* When sticking to standard Java, it is extremely portable by virtue that it
is an interpreted language. And there are Java runtimes (of one version or
another) on virtually every platform.

All of the above in my opinion would lead me to suggest that Java is
"easier" to use and learn - even if it is not "better". But hey, that's just
my opinion. On the other hand if you are going to learn both, I would
probably start with C++ because you will get a better practical sense of OO
design, and it will definitely be easier to switch to Java from C++ than the
other way around... not to mention you will pick up some nasty habits from
doing too much development in Java. ;-)

I also have some comments regarding the statements bellow:


> Swing (the Java GUI classes) are a real pain, the C++ GUI
> classes I know are easier to handle, some are available
> for several platforms. Java is less portable than C++ if
> you use portable C++ GUI classes, even if SUN tries to tell
> us something different. Swing is extremely version dependant,
> even a minor version change can make your program fail to run.


I don't know if you are talking about Swing or AWT, but in either case they
are not much different than any other GUI framework. I actually prefer Swing
to MFC. As far as being portable.. well, I have no idea what you are talking
about.. how is C++ going to be _more_ portable than Java? Especially GUI?

> Java itself isn't a bad developement language, but only for
> backend stuff.
> Java only for very specific things, web services for example,
> but never for GUI programs.

I would urge you to look at some commercial applications built with Java,
like: JBuilder, InstallAnywhere, Magik, or Limewire, for example. Most
people probably wouldn't even know that they were Java apps. Of course you
won't get exactly the same performance from Java that you would from
something built with C++, but you do get the robustness of using the Java
platform.

> Otoh.: Ask 10 program developers and you will get 10 different
> answers ;)

That's the truth!

Peace.
-ff

[View Quote]

.duo.

Feb 17, 2003, 10:47pm
Example of evil C++ memory error:

#include <iostream.h>

struct MemErr
{
int crash;
};

void main()
{
while(true)
{
MemErr *Omega=new MemErr;
}
}

I assure you that if you put that into a C++ document and run it, it will
eventually crash your computer, or at least everything its running. I
forget but I think you have to do "Delete Omega;" or something to delete it
from memory so it doesn't crash your computer.

[View Quote]

grimble grimble2000@btinternet:com

Feb 18, 2003, 1:00am
Oh bloody hell! Well all I can say is that if you haven't even grasped the
basic requirements of C memory management, then you shouldn't be touching it
or C++ anyway. Having no garbage collection in C++, in my opinion, makes for
better understanding of his/her application by the developer as you're
forced to respect the context of an object or store.

Its not an "evil C++ memory error", its code written by someone who hasn't
made he effort to lean the fundamentals of a language. Of course, there are
so few free resources around for learning C++ on the web that its hardly
surprising someone would fall into that trap. Blimey Guv'nor!

Grims.

[View Quote]

bowen

Feb 18, 2003, 1:06am
[View Quote] He likes to use dynamic memory allocation a lot... that seems to be his downfall too.
Bowen thinks .duo. should stick to static sized variables.

--Bowen--

.duo.

Feb 18, 2003, 11:14am
Yeah, maybe I should >_< takes up less memory for one. Its just the
programming style I got into after I forgot most of C++, heh heh heh. I at
least used to know everything basic and useful.

You don't have to attack me though grimble...

Obviously if something in a program doesn't work correctly... it either is
an error or has an error. I wrote that code to purposely show whats bad to
do with DMA, I actually know, or at least knew everything about DMA >_<
Maybe I should just go read a book or something, lol
[View Quote]

grimble grimble2000@btinternet:com

Feb 18, 2003, 12:01pm
heh ... Wasn't an attack, was pure, unadulterated frustration at reading
complete trash.

What utter crap, geesh! Surely you have to be making this up.


[View Quote]

agent1

Feb 18, 2003, 4:38pm
There is no error in the behavior of the program. It is doing exactly what you tell it to: Allocate a new object forever. It only crashes because your computer doesn't have infinite memory.

-Agent1

[View Quote]

.duo.

Feb 19, 2003, 12:14am
Damn, I can't post one little thing without getting attacked 5 times >_<

[View Quote]

bowen

Feb 19, 2003, 12:16am
[View Quote] What can I say, we like what we do best.

--Bowen--

agent1

Feb 19, 2003, 4:38pm
Only if your definition of being attacked means having your errors pointed out... I don't see any posts insulting you as a person, just ones saying what's wrong with the code you're basing something on.

-Agent1

[View Quote]

.duo.

Feb 21, 2003, 12:29am
Anyway, can anyone offer any help in me running the bot as an admin client.
I know its way too advanced and crap but I really need to add CTs and get
rid of them too, beacuse demeter done terrain looks like crap.

1  |  
Awportals.com is a privately held community resource website dedicated to Active Worlds.
Copyright (c) Mark Randall 2006 - 2024. All Rights Reserved.
Awportals.com   ·   ProLibraries Live   ·   Twitter   ·   LinkedIn