Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2006

Tip: Looking for answers? Try searching our database.

Learning Java

Thread view: 
Tuvas - 25 Mar 2006 17:04 GMT
Hey all,

I have been a C programmer for a number of years, and am needing to
learn Java. I would like to get a book about it, but I am hesistant to
just buy a beginners guide to Java, fearing that my knowledge of C will
cause me to not pay much attention to it. I would like to get a book on
programming in Java for those who know C, or something along those
lines. Can anyone recommend a book for me? Thanks!
Joe - 25 Mar 2006 17:09 GMT
http://www.computer-books.us/

Just found this on digg.com.  There's a couple of Java books for
download there.

As for the switch from C to Java, you mainly need to wrap around the
Object-Oriented idea.  C++ covers this in great detail (I went pretty
seamlessly from C++ to Java, just because SO many of the principles are
the same).  I don't think they really make a book specifically for Java
for C programmers, but most should be able to give you the OOP
introduction, and from there you should start to pick it up pretty
well.

Also, another great tool is the Java API.
http://java.sun.com/j2se/1.3/docs/api/.  I know, it's a lot to digest
now, but once you start getting into the language, that will explain
EVERYTHING you'd need to know about certain objects.

Happy hunting!
Thomas G. Marshall - 26 Mar 2006 06:42 GMT
Joe said something like:
> http://www.computer-books.us/
>
[quoted text clipped - 5 lines]
> seamlessly from C++ to Java, just because SO many of the principles are
> the same).

... *no one* goes seamlessly from anything to C++ nor from C++ to
anything.... ;)

Signature

Framsticks.  3D Artificial Life evolution.  You can see the creatures that
evolve and how they interact, hunt, swim, etc. (Unaffiliated with me).
http://www.frams.alife.pl/

Bjorn Abelli - 26 Mar 2006 16:33 GMT
"Thomas G. Marshall" wrote...
> Joe said something like:
>> http://www.computer-books.us/
[quoted text clipped - 9 lines]
> ... *no one* goes seamlessly from anything to C++ nor from C++ to
> anything.... ;)

But the "transition" from one language to another can be more or less easy.

I have experienced C++-programmers that had difficulties in grasping Java,
and C++-programmers who got to it quickly.

Many "C++-programmers" made their way into C++ from C, not realizing the
strengths of OO-programming, using it more or less only as an "enhanced C".

Other C++-programmers have started from the perspective of learning
OO-programming, using C++ during learning the OO-concepts, as the language
to implement their newfound knowledge.

The latter group had obviously an easier path to Java, than the former.

// Bjorn A
Thomas G. Marshall - 26 Mar 2006 16:57 GMT
Bjorn Abelli said something like:
> "Thomas G. Marshall" wrote...
>> Joe said something like:
[quoted text clipped - 28 lines]
>
> // Bjorn A

Oh of course; I was clearly being glib.

Your point about C++ programmers using C++ as an uber-C is a very good one,
but there is a larger generalization to make here.  However, observations on
the shortcomings of C++ have been made so many times that if printed out the
paper would no doubt collapse upon itself and form a star, in a very
Adamsarian way.

;)  And that part was not being glib.

Signature

"His name was Robert Paulson. His name was Robert Paulson. His name was
Robert
Paulson..."

Rhino - 25 Mar 2006 17:25 GMT
> Hey all,
>
[quoted text clipped - 4 lines]
> programming in Java for those who know C, or something along those
> lines. Can anyone recommend a book for me? Thanks!

I can't recommend a book on Java for C programmers but I'm pretty sure there
are some. I'm sure I've seen this question asked and answered on this
newsgroup before. Try doing a Google Groups search of
comp.lang.java.programmer and search for 'C' and 'Java' (and maybe 'learn')
and you should find several recommendations.

--
Rhino
abuggia@gmail.com - 25 Mar 2006 17:35 GMT
I'd recommend Hardcore Java (O'Reilly).  I could not get through
Learning Java because I knew how to program and it was too slow.
Hardcore Java teaches you advanced techniques and concepts and I was
able to pick up on syntax along the way.
Patricia Shanahan - 25 Mar 2006 17:46 GMT
> Hey all,
>
[quoted text clipped - 4 lines]
> programming in Java for those who know C, or something along those
> lines. Can anyone recommend a book for me? Thanks!

I've tried both conversion books and beginner books for learning new
languages, and I find beginner books MUCH more effective.

It's a matter of mental mindset. Every language corresponds to a model
of how programs work. Someone who is comfortable with a language's model
is much more likely to produce smooth, effective code in that language
than someone who is thinking in the model from a different language.

The more I make myself ignore all the other languages I know, and focus
on the language I'm learning, the better I do at getting my brain
wrapped around the right model.

The "programming in X for those who know Y" books tend to keep me
thinking in language Y's model, rather than getting me into language X's
model.

This is perhaps most important of all for the C to Java transition. A
lot of Java syntax looks superficially like C, but the model of what is
going on underneath is profoundly different.

Patricia
Tuvas - 25 Mar 2006 17:57 GMT
I should probably mention I've had a taste of object-oriented
programming, with Python. I'll look into the Hardcore Java for sure.
Thanks for all of your help!
Roedy Green - 25 Mar 2006 19:18 GMT
>This is perhaps most important of all for the C to Java transition. A
>lot of Java syntax looks superficially like C, but the model of what is
>going on underneath is profoundly different.

It is almost to the point I think knowing C++ first made learning Java
slower.  There are so many superficial resemblances.  Also I tend to
think in terms of machine language. I like to understand just what is
going on under the hood.  Java is a quite abstract language and
deliberately tries to fog that over and provides no low level tools to
peek., e.g. just what does an object look like in RAM.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

Roedy Green - 25 Mar 2006 18:44 GMT
>I have been a C programmer for a number of years, and am needing to
>learn Java. I would like to get a book about it, but I am hesistant to
>just buy a beginners guide to Java, fearing that my knowledge of C will
>cause me to not pay much attention to it. I would like to get a book on
>programming in Java for those who know C, or something along those
>lines. Can anyone recommend a book for me? Thanks!

see http://mindprod.com/jgloss/cpp.html
for some recommendations.

I learned C++ first.  I got in SO much trouble imagining that Java
worked the same as C++ just because the syntax looked familiar.

Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

Alex Hunsley - 26 Mar 2006 03:35 GMT
> Hey all,
>
[quoted text clipped - 4 lines]
> programming in Java for those who know C, or something along those
> lines. Can anyone recommend a book for me? Thanks!

Such "C to Java" (or similar) guides can be pretty useful. But an
important step, as others have pointed out, is getting sufficiently used
to a new language such that you're not thinking of it in terms of
another more familiar language you already know. Getting to know a new
language in direct, first principle terms is pretty essential if you're
going to do any significant amount of work on it. As an example of what
may otherwise happen: you sometimes see programmers going out of their
way to make a new language look like, and behave like, a language that
is more familiar to them. Bully for them, perhaps, but as soon as other
developers come along, more proficient in the language in question, they
will look at the Frankenstein code and see a confusing mess.
Roedy Green - 26 Mar 2006 06:49 GMT
On Sun, 26 Mar 2006 02:35:17 GMT, Alex Hunsley
<lard@tardis.ed.ac.molar.uk> wrote, quoted or indirectly quoted
someone who said :

>you sometimes see programmers going out of their
>way to make a new language look like, and behave like, a language that
>is more familiar to them.

One of the keys to writing Java is to be familiar with what is in the
enormous class libraries. You rarely write your own algorithm style
code.  In C you usually presume you are going to gave to roll
everything on your own.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

weironghai@gmail.com - 26 Mar 2006 07:55 GMT
haha you can find a book named c++and java.that ont only have java &c++
bu also c.best wishes for you to learn java  .i 'm a tyro too
Thomas G. Marshall - 26 Mar 2006 17:00 GMT
weironghai@gmail.com said something like:
> haha you can find a book named c++and java.that ont only have java &c++
> bu also c.best wishes for you to learn java  .i 'm a tyro too

If English is not your native language forgive me, but otherwise, I have no
@#$%ing idea what you just said.

Signature

"His name was Robert Paulson. His name was Robert Paulson. His name was
Robert
Paulson..."

Missaka Wijekoon - 26 Mar 2006 04:16 GMT
> Hey all,
>
[quoted text clipped - 4 lines]
> programming in Java for those who know C, or something along those
> lines. Can anyone recommend a book for me? Thanks!

I would recommend attempting to do a small project in Java.  Like you, I
started with C.  It was easy to pick up Java's syntax and grammer, but
the elegance was only realized as I started extending objects, creating
and using interfaces, abstract classes, exceptions, etc.  I noticed that
Java allows me to spend more time in design whereas C requires more time
coding (leaving less time for design.)  In the beginning, inevitably,
you will write some Java code in C-style.  But as you get to know the
language you will go back and realize what you could have done better.
Dive in!  I found that C made me better Java coder and that Java made me
a better C coder.

Good luck!
Tuvas - 26 Mar 2006 05:00 GMT
It sounds like learning a new computer language is just like learning a
real language, you start out with the other languages you already know,
but eventually need to become fluent in itself. Thanks for all of the
tips!
petermichaux@gmail.com - 26 Mar 2006 17:02 GMT
A quick find didn't show the mention of "head" in this thread so...

Head First Java : Your Brain on Java - A Learner's Guide

This book is great. Read the reviews on amazon. People like this. So
did I. It makes Java jargon make sense quickly.

Peter
petermichaux@gmail.com - 26 Mar 2006 17:02 GMT
A quick find didn't show the mention of "head" in this thread so...

Head First Java : Your Brain on Java - A Learner's Guide

This book is great. Read the reviews on amazon. People like this. So
did I. It makes Java jargon make sense quickly.

Peter
Roger Dodger - 26 Mar 2006 20:53 GMT
I liked Core Java 1:Fundamentals  and  Core Java 2:  Advanced Features
by Cay Horstmann.  Covers a wide variety of features and functionality
of the language, and has sidebar icons to draw attention to how the
language differs from C/C++.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.