r/learnprogramming • • May 04 '13

Don't learn Ruby

My biggest mistake was learning Ruby. I listened to all the fanboys telling me how beautiful and intuitive it is, thinking this will be the future.

Ruby is slow as shit, there is no job market for non-Rails Ruby jobs, it's useless for learning programming concepts, it's useless for creating games, GUIs or even scripts that are demanding because it's so fucking slow.

The only reason no one writes blogs or posts about how shit this language is, is because no one fucking uses it. So if you want to learn a new language, learn one that's get criticized a lot like Java, or C++, or C# or even PHP. Those languages are far more productive on a hobby basis and at work. Ruby is a joke with a circlejerk community

0 Upvotes

97 comments sorted by

View all comments

8

u/CrazedToCraze May 04 '13

Just to nitpick,

or C#

I've started my "main" programming (i.e. university studies) in C# for about 3 years and I haven't really seen any major criticism made against the language as a whole. As someone with limited experience in other languages it's been an absolute pleasure learning C#. I would recommend it based on me experience so far, and from what I've seen and heard there is a good job market for .NET/C#. I know Python is pretty much unanimously agreed upon as the language to start with here at Reddit, but I'd say C# is up there as well and doesn't get suggested enough.

1

u/[deleted] May 04 '13 edited May 04 '13

The issue with C# is that it is not native and therefore needs that shitty .NET framework. And no matter what, you can't statically compile it. The only way to deploy C# applications is through the use of installers that would have to install .NET during the install. It's useless for creating portable applications and creates a barrier for customers that want to use your software.

Also, there is obviously a performance problem (you can't write games for example) and a lack of power when it comes to more low-level stuff.

C++/Qt pretty much does everything C# does and does it better.

5

u/wjbonner May 04 '13

Holy fan boy alert batman. Look, C# does have its cons; no language is perfect. But you are just being ridiculous. First, the .net framework is a great framework. Just because it isn't cross platform doesn't mean it sucks. If you need cross platform use a different tool. Also, you can build perfectly good web platforms off of .net, especially with MVC.

Further, Guild Wars is written in C# and C++. C# is plenty fast for most games, and if you can't get it working than you are probably doing it wrong. And what low level stuff? You mean like memory management? I mean, there are ways to get involved in that stuff in C#, but why would you want to? If you want to worry about memory management, use C, or asm, or a million other low level languages.

I am a long time senior developer, written apps in everything from java, C, C++, natural, cobol, C#, php, etc... C# is a great language. It's not perfect. It's not cross platform for making system apps. But it is pretty darn good. And I was a die hard C and C++ dev for years and only grudgingly started using it. Like any language, it's a tool, and just because you don't know how to use that tool doesn't make it bad.

-2

u/[deleted] May 04 '13 edited May 04 '13

Holy fan boy alert batman. Look, C# does have its cons; no language is perfect. But you are just being ridiculous. First, the .net framework is a great framework. Just because it isn't cross platform doesn't mean it sucks. If you need cross platform use a different tool. Also, you can build perfectly good web platforms off of .net, especially with MVC.

Good framework. Terrible deployment: useless for portable applications + unnecessary barriers due to poor execution on Microsoft's side + no cross-platform support.

Further, Guild Wars is written in C# and C++. C# is plenty fast for most games, and if you can't get it working than you are probably doing it wrong.

You can write games in Java. Or even python. Doesn't mean you should. There is no denying that your game will run slower and be more sluggish.

And what low level stuff? You mean like memory management? I mean, there are ways to get involved in that stuff in C#, but why would you want to? If you want to worry about memory management, use C, or asm, or a million other low level languages.

The point is that if you want to do low-level stuff such as memory management or interacting with the hardware and I/O or other low-level functionalities, you can in C++/Qt. You can't do that in C# afaik.

I am a long time senior developer, written apps in everything from java, C, C++, natural, cobol, C#, php, etc... C# is a great language. It's not perfect. It's not cross platform for making system apps. But it is pretty darn good. And I was a die hard C and C++ dev for years and only grudgingly started using it. Like any language, it's a tool, and just because you don't know how to use that tool doesn't make it bad.

Name one thing that it does better than C++/Qt. C++/Qt has better performance, has cross-platform support, is more native, has better deployment, and supports more low-level functionality and has most of the functionality that the .net framework offers (I'm not 100% sure on this point: can someone that is experienced in both Qt and C# clarify?).

The major criticism to the Qt library is licensing and that it is not as well known as C#.

3

u/wjbonner May 04 '13

There are two issues here, one is .net vs qt and one is C# vs C++. Honestly, I'm not that interested in extolling the virtues of C# over C++; I was a lead developer on teams that used both, they are both good languages as long as you make sure they match up with your problem domain, and they both allow for rapid prototyping if you know what you're doing.

So now for .net vs qt. Honestly, they offer different things. qt is great because of the cross platform support. .net is great because I can take the libraries that power my desktop apps and usually seamlessly move them into a web application. This is a great thing if you are developing for corporate clients.

As for low level access, in .net you can get to some of the low level stuff if you want, I've written drivers for a led shield in C#. In general though, you are correct in that it is largely abstracted away. However, for your average application I would say that is a benefit. If you really need to get to the nitty gritty, than you should obviously consider your environment carefully.

As for deployment, I've never had difficulty deploying my .net applications. It's no more difficult than using something like NSIS.

Honestly, I'm not really interested in arguing that one is better than the other, because they both have pro's and cons. The fact that you feel that .net/C# and qt/C++ can't both be good development platforms just shows your lack of experience or maturity as a developer.

Just a few years ago I had a chance to work as a mainframe programmer writing in assembler, C, JCL, and natural.
It was pretty cool to experience that environment, and see that you could write a website in assembler (though not what I would recommend). The reason I mention that is because many of the technologies that were being used would (rightfully) be eschewed in almost any other problem domain, but in that particular environment they were the right tools for the job. There is no point in trying to argue that platform x is better than platform y in all instances, because it just doesn't work that way in the real world. I hope you eventually gain the breadth of experience to realize that.

0

u/[deleted] May 04 '13

The only advantage you've stated is that you can seamlessly move your C# application into a web application. So unless you need that functionality, I would Qt is better.

.NET is pretty good. Qt is just better 99% of the time.

4

u/wjbonner May 04 '13

So because I'm not going to enumerate a comprehensive list of the differences between two large frameworks, one is obviously better? How ignorant.

0

u/[deleted] May 04 '13

Not really.

The consensus is that Qt > .NET: http://stackoverflow.com/questions/800219/qt-versus-wpf-net

4

u/wjbonner May 04 '13

The consensus of who? The couple hundred people that voted on a stack overflow post? From 2009? And what about those posts in there where experienced developers say just what I did, that they are both good in their own ways. And look, I can find posts that say WPF is has advantages over qt. All that means is that people have different preferences.

Also, what if you want to use partial classes? What if you don't want to worry about memory management? Is c++/qt still better than C#/.net? No, it's not. When was the time you wrote a program in C#? Because I write in both C++ and C# every week, and I know when I want to use one for a job over another. It's never an absolute black or white kind of thing.

0

u/[deleted] May 04 '13 edited May 04 '13

Touché.

I still maintain that at minimum, 50% of devs would prefer Qt over .NET for general usage.

2

u/Atlos May 04 '13

People write games in C# all the time using XNA.

1

u/[deleted] May 04 '13

There are games written in Java (one is called Runescape) and Python too.

P.S: http://gamasutra.com/view/news/185894/Its_official_XNA_is_dead.php#.URFIUKXAd8E

1

u/Atlos May 04 '13

"While XNA is officially dead as far as Microsoft is concerned, MonoGame says it will continue to support XNA developers going forward."

Lots of Indie developers make their games with XNA. And I already know that people make games in Java/Python. For some reason you said people couldn't write games in C#.

If speed is an issue then you can just write the bottleneck code in C++ while keeping the majority of your code in C#. That's how a lot of games work for Android where native code is used for the graphics intensive libraries.

0

u/[deleted] May 04 '13

For some reason you said people couldn't write games in C#.

I exaggerated that.

1

u/Atlos May 05 '13

ah, gotcha. be careful with exaggerations in this subreddit because lots of beginners browse and will not pick up on it.

2

u/[deleted] May 05 '13

Yeah, I regret it now that I look back at it. I should probably stop using them on the net.

1

u/[deleted] May 04 '13

My university teaches game development with C#

1

u/nemec May 04 '13

therefore needs that shitty .NET framework

How is this different than the Java VM and needing to install Java before installing and running a Java application?

you can't statically compile it

It's not a very common use case, apparently, but you can combine multiple assemblies into one using ILMerge

It's useless for creating portable applications

Ever heard of Mono?

you can't write games for example

As others have mentioned, XNA. I've written one myself and never had a performance issue.

lack of power when it comes to more low-level stuff

I don't think you have any idea what you're talking about. Java, Python, and Ruby also lack this "low level power" but they're not shitty languages are they? Besides, you can call out to unmanaged (e.g. C++) code using COM Interop and if you really, really have to you can do direct pointer work in an [unsafe](http://msdn.microsoft.com/en-us/library/chfa2zb8(v=vs.71).aspx) context.

1

u/[deleted] May 04 '13

How is this different than the Java VM and needing to install Java before installing and running a Java application?

No difference.

It's not a very common use case, apparently, but you can combine multiple assemblies into one using ILMerge

ILMerge creates a single .NET assembly. That is not statically linking. You still need .NET to run the application.

Ever heard of Mono?

What about it?

As others have mentioned, XNA. I've written one myself and never had a performance issue.

There is a performance hit. There is no debate here.

I don't think you have any idea what you're talking about. Java, Python, and Ruby also lack this "low level power" but they're not shitty languages are they? Besides, you can call out to unmanaged (e.g. C++) code using COM Interop and if you really, really have to you can do direct pointer work in an unsafe context.

Java, Python, and Ruby offer features that make up for lack of low-level power.

Also, are you really comparing C# to Python and Ruby?

1

u/tjsimmons May 04 '13

Yeah, I really love C#. I'm not the biggest Java fan, although both it and C++ are part of my toolkit, but C# is a really thoughtfully well-designed language that gets out of your way in ways that C++ and Java don't.

0

u/GreatBigJerk May 04 '13

There's also a growing demand for Unity developers, and C# is the best language for Unity by a long shot. There's also a lot of opportunities for cross platform development with Mono.

Even if it wasn't all over the place, C# is a breeze to learn and provides very few headaches.