I am thinking of creating a game just for fun. What are the advantages in programming in these languages?
I believe Unity and Java both have their own embeddable applet thing and C# has a software package (XNA Game Studio) ready for developing games for Windows Phone, XBOX 360 and PC.
Just some criteria:
I want to develop games for PC.
Allow me to put my support behind C# and particularly XNA.
With the use of Mono (including paid libraries like MonoTouch and MonoDroid), you can get C# running pretty much anywhere (eg). C# is certainly fast enough for game development. And the runtimes are very much stable. It can run in-browser via Silverlight.
In my opinion, C# is superior to Java as a language, especially for game development, and especially considering tool and library support - especially XNA.
XNA is a game development library (similar to DirectX in scope) and there are also plenty of libraries built for XNA. In addition is has by far the best library of sample code available.
XNA runs natively on Windows, Xbox 360, Windows Phone 7 and (an older version) on Zune.
On PC, C# and XNA each require runtimes. Microsoft's ClickOnce installer makes this very easy. It gives your user a bootstrap installer, which then downloads and installs the runtimes from Microsoft as necessary. The .NET 4.0 Client Profile is 41MB and XNA 4.0 is 7MB. This answer has more details.
In addition there are projects that port XNA (2D API only) to other platforms. I am currently funding a project called ExEn with the goal of bringing a high-quality 2D XNA implementation to the browser (Silverlight), iOS, Android and Mac.
If you can't wait for ExEn, you could try some of the libraries it is based on - SilverSprite (Silverlight) and XnaTouch (iOS). SilverSprite is quite buggy, XnaTouch is a bit better.
(At the moment, if you want to do a 3D game on these platforms, Unity is perhaps a better option.)
To be clear, Unity isn't a language (like C# and Java), it is an authoring tool and runtime. You write your game's logic in C#, UnityScript (flavor of JavaScript) or Boo (flavor of Python). The authoring tool is quite stable and powerful and gives small teams a fantastic pipeline for adding 3D models, textures, sounds, shaders, etc.
In my (fairly long) professional career as a game developer I've only used one authoring tool that was superior to Unity, and that was an in-house proprietary tool developed over many years by a team of top-notch engineers.
There's no equivalent to Unity in the Java world that I'm aware of. XNA will give you a head start if you're writing straight C#, but you'll still have to create/integrate a lot of fundamental stuff (physics, particle systems, collision detection) before you're even close to what you could accomplish day 1 with Unity.
Standalone Unity games can be built for Mac or Windows. The standalone build doesn't require the user to install Mono, and is very stable in my experience. There is also a Unity Web Player that allows games to run in A-class browsers on Mac and Windows. The web player is only installed on about 35 million browsers (sounds like a lot, but consider Facebook has over 500 million users).
I know I sound like a shill, but Unity really is a great tool.
i dont think its about programming language anymore. its depend on your target platform.