views:

665

answers:

14

Learning just another language is not much work. However, getting familiar with all the supporting libraries is veeeery expensive and actually you cannot go too far without that.

Would you consider a worthy career investment to learn java once you already are an accepted professional of .NET or you would rather invest the same amount of energy to get deeper in the things you already know?

A: 

Not sure. At the moment, the market (in Belgium) is so much demanding about .NET professional that I'll dive more and more in the .NET depths. But I'd keep an eye on other technologies as well.

Fabian Vilers
A: 

I focus on C# because it is demanding in my region, however, I love Java since there are so many great open source libs, e.g. GeoServer, GWT, Hibernate, Spring, Android and many.

.NET and Sun Java are both worth the investment.

codemeit
There's a .Net Spring too. Same with (N)Hibernate. For GWT check out Script# http://projects.nikhilk.net/ScriptSharp/
cletus
But they started with Java, isn't it. I guess google not likely wants to start a brand new project with .NET, they want to be neutral with open technologies.
codemeit
+2  A: 

Once you learn the most important concepts of some programming language and its framework, it is relatively easy to adapt to another one. .Net and Java world are similar and migration to from one to another is easy, so I recommend you to do it. I did it two times, from Java to C# and reverse, but I am working with company which have projects in both languages, so I can apply my skills and I have very experienced people in my surrounding which can help me.

Nenad
+14  A: 

Most of the cool things about Java are its supporting open source tools, which are being ported to .Net anyways, like NHibernate, NUnit, and Spring.Net. Having both Java and .Net under your belt could be vary valuable in certain circumstances, especially in financial services, where they use both and interop between the two on a regular basis.

If you don't plan on doing Java, then I would say to delve deeper into the framework. Learn WCF or WPF. If you want to expand your mind, learn F#, which will make you a better programmer in general with functional programming under your belt.

It wouldn't be a "waste of time", but you have to ask yourself what your goals are.

Charles Graham
+1 Agree 100% and I say that as a Java programmer for 10+ years. Don't bother unless you need to. The idioms are the same or very similar so you won't really gain that much.
cletus
A: 

It's always worth gaining familiarity with a commonly used language in case you ever run into it. Who knows if one day you come into work and your boss says "We just merged with Ajax Widgets and we're taking over their web site, it's all written in Java, start converting it." or worse "Start maintaining it. Here's a list of new features we need."

Whether you gain competancy in it or not is up to you, but you should at least be familiar with it if you plan to be more than a one trick pony.

Mystere Man
A: 

It depends on your goals.

Learning Java might be a waste of time if you're never going to use it. It might distract you from C# and lead you to forget some things. They are very similar languages so you're probably not going to learn any groundbreaking new programming skills in the process.

+4  A: 

From a similar position I'm going with "no".

There's so much other stuff I need to be learning (more .NET, more rails, silverlight) which is relatively high gain to cost. Learning Java might not be too hard but learning the stack the typically comes with java (be that PHP, JSP, structs, spring, eclipse, whatever) doesn't seem to add a lot of value to me.

In the long run yeah learn everything, but me personally I think I'm more valuable if I add diversity of other solutions rather than reflection of another solution to the same problem. Yeah that might cost me opportunities working for a !MS shop, but I can live with that with the popularity of .NET and rails.

annakata
+1 for that!! :) I have the same thought
Shoban
-1 PHP is not on a java stack
l_39217_l
A: 

First things first, I agree with your opening statement; I would also add that time should also be invesed in learning about the common patterns, how and when they are applied, and why. Java has it's own special take on OO and is full of neat ways to reduce code duplication and allow polymoprhpism and ensure everything is sill flexible and so on, but they are not all intuitive at first.

I believe it will always benefit you to learn another language as it will give you another mental tool to use when attacking programming problems.

So I presume you can write Hello World or its equivalent in a variety of different languages, including Java. But the question is, how much of the Java platform (the Java atandard libraries, the popular frameworks, and so on) should you learn, and how much time should you invest in it?

That is difficult, and of course depends on what you want to do. In my humble experience (~10 years as a developer) learning a specific platform (in your case, .Net) is more useful than investing large amounts of time learning a second platform that you won't be using all the time. Whilst it is nice to see how competing platforms solve similar problems, they often turn out to not be terribly useful in your own platform, or almost exactly the same. So in short, I would say if you wish to remain a .Net developer, stay in .Net, and learn another aspect of it that you haven't looked at before. Learn a little bit of Java but don't spend too much time geting into Swing or Struts or Spring because it wont be that useful to you as a .Net developer.

And if you want to really excercise your mind try languages that are far removed from both .Net and Java - c, lisp, haskell are fun!

andy K
+1  A: 

In brief: No.

Don't do this as a career move unless you have actual code to write. The only way to learn a language well is to write code in it - a LOT of code - so you need to have this included in your planning.

If you NEED to learn Java in order to apply for another job, and you cannot do this in your day time work, then consider finding an Open Source project written in Java which you would use on a daily basis and contribute to it. Write documentation for existing code if needed - support users if needed - improve bugreports to help the committers - or even write code for it. All these efforts allow you to get familiar with the project code, both in usage but also by reading it to be able to understand how stuff works and what people that report bugs are trying to say.

This makes you a valuable contributor, which is exactly what you want to be to your employer. Doing it on an open source project allows you to SHOW the project to the employer and let them see for them selves what you can do, instead of just waving your arms.

Thorbjørn Ravn Andersen
+2  A: 

Your time could be better spent learning more .Net. I'm assuming though that you're thinking of learning java as a way of expanding your toolbox, in which case I'd point you more to the scripting languages. Be it python, ruby, perl or something else entirely, assuming you're not fluent in any of those.

Sometimes you need a light-weight quick and dirty solution. Java and .Net can be used in those instances, but if a 20 line script will suffice, why bother starting up your IDE in the first place? If you feel confident in any scripting language it will help you do simple stuff like that quicker and easier and encourage you to do that more. That and the added plus of most popular scripting languages now being able to run on either VM.

wds
A: 

In this economic times I would consider learning Java. Really the only way I would go into hard core learning would be if my job required it. We are a .Net shop but our parent company is a java shop and we are talking about combining all our ecommerce stuff into one common platform so depending on what direction that goes I might have to learn Java.

I wouldn't do it just to learn Java at least not right now.

Robert
A: 

Given that Java and C# are so similar perhaps a different approach to learn Java and its ecosystem would be useful. Why not look into Scala which is a functional/object hybrid language that runs on the JVM, uses the Java libraries and deploys like Java. This will get you some experience in that world while at the same time learn a very different style of programming.

dpp
A: 

Learn good development practices and then the language becomes secondary. switching from one C style OO language to another is fairly simple and it doesn't mater if it's c++, java, c#, and php to a lesser degree.

The java world is a little older and a little more mature so they have learned a lot of the hard lesions already try checking out "Head First Design Patterns" the authers are java guys but the patterns apply to any C style OO language

Bob The Janitor
+1  A: 

Yes, I would learn Java. In fact, I would switch to Java. Here's why (don't downvote please, I'm not trying to start a holy war, just pointing my observation)

  • corporate .NET harbors many junior developers (including senior dudes who are junior developers) as well as junior managers
  • consequently, the junior .NET crowd seems to favor predictability over innovation and tends to believe in Elixir of Eternal Youth and the Philosopher's Stone (a joke by Dijkstra)
  • JVM ecosystem seems to lead the innovation in the areas of design, architecture and best-practices (IoC, ORM, EIP just to name a few). Open source .NET community is mostly playing catch-up game, with projects like NAnt, NHibernate, etc. Truth be told, there's a radical cutting edge crowd in .NET too (sometimes known as Alt.NET) but its reach is limited and its projects often die in version 0.2
  • JVM innovation is mostly driven by OSS community (and therefore diverse), while .NET innovation is almost all driven by large players like Microsoft (ASP.NET MVC, C# language enhancements) and Novel (Mono).
  • in terms of language innovation, with JVM you're not limited to Java, there are Groovy, Clojure and Scala; finally, you can even coexist with JRuby. there are alternative languages in .NET too: Boo, IronRuby, Delphi Prism but they are either too niche, lacking community support, or belong to corporations that are likely to drop them at any moment.
zvolkov
You are generalizing way too much. Without even working with Java on a day to day basis I can tell you with certainty that it has more junior developers just because of a higher usage. Also, considering how new .NET is and how far it has gone I would have to say innovation is not an issue.
ChaosPandion