tags:

views:

467

answers:

8

Is it worthwhile learning C# if you are a Linux user? There is Mono but it seems destined to always be behind the curve with the constant threat of MS action if they start to lose money.

Currently I am leaning more towards Java as its is fully GPLed and there are no major threats of software patents. It already has a big oss community behind it and has a solid reputation on the server whereas C# still needs to prove itself there.

The big advantage for C# programmers is that they are cheaper than Java developers. I also wonder exactly how portable C# code is though. Can one simply take a C# app written to target Mono and run it on windows?

A: 

Given your scenario, me personally I would learn Java, as you will find the transition into C# further down the line, quite smooth. Also having Java under your belt is a very good thing. I would say Java is much more portable than C# although you have the option of using the Compact Framework, which will be quicker to bootstrap with your program.

REA_ANDREW
+8  A: 

I've written a number of C# command-line programs, specifically to run as distributed simulation engines, that were targeted for Ubuntu. They work perfectly there or on Windows.

It's hard to say what the future holds, but C# is a powerful language and I think it's worth learning even just for our personal growth. I despise Windows myself but have been writing C# for a while (for Windows mostly) since it pays the bills.

Novell uses Mono extensively for their Linux applications and I think that their relationship with Microsoft adds some weight to the idea that .NET for Linux will stick around.

Here's a list of some of the companies using Mono.

Andrew Flanagan
+2  A: 

"on the server whereas C# still needs to proof itself there"

You do know MySpace is built ontop of ASP.NET, right? Millions of hits a day running off a C# backend.

Quibblesome
PlentyofFish too and they do it all on one or two servers.
Echostorm
and, needless to say, Stack Overflow.
Can Berk Güder
A: 

I work for a company that uses both Java and C#. I prefer C# because I think Visual Studio blows away Eclipse, and I just like the language better. However, I think you might do better learning Java in your case. You have more flexibility both for your project and career-wise. You can learn C# anytime.

Andrew Cowenhoven
I prefer Visual Studio over Eclipse -- but I prefer SharpDevelop over Visual Studio. Have you tried it before?
Andrew Flanagan
A: 

C# is a nice language, and I find it much easier to work with than C/C++, especially for GTK applications.

I also think that learning C# would be a much better investment than learning Java. I'm saying this for no other reason than my personal taste, but I also honestly and objectively believe that C# will have a better future than Java.

As for running Mono apps on Windows, you can usually do this without a hassle, but if it's a GUI application, you will either have to create a Windows version that uses Winforms, or your users will have to install GTK for Windows. Either way, your applications will have a much better look and feel than Java applications on both platforms.

Finally, I don't think M$ will take legal action against Mono anytime soon.

Can Berk Güder
+2  A: 

This question has already been asked and answered many times on SO.

Is Mono ready for prime time?

Why Use Mono?

postfuturist
+1  A: 

Sorry for the flame-bait, but I've personally had more portability success with mono, than java. Not a blanket statement, just my experience.

A: 

It works very nice. IMHO you should use Mono from the development site (www.go-mono.com) rather than version provided with your distribution.

Also you could try dry-running it with VMWare machine that is also avaliable on the official site.

Migol