r/learnprogramming • u/Intelligent_Role_824 • Aug 09 '26
Ruby vs. Rust for a hobby programmer. Which one should I pick?
Hey everyone,
I'm looking to learn programming purely as a hobby (definitely not looking for a career change). I've tried out a bunch of different languages, including Python, which honestly didn't really click for me, but the two that I found super cool and really enjoyed are Ruby and Rust.
I'm well aware of how completely different they are. One is high-level and expressive, the other is system-level and super performant. Even with those differences, I'm equally interested in both and can't decide where to start.
Long term, I'd love to build a mix of side projects just for fun, like:
A simple Web App / REST API
A real-time chat application
Maybe some Desktop Apps down the road
Since my main goal is just to have fun, learn, and build cool stuff, which one would you recommend starting with?
Appreciate any thoughts or advice!
42
u/Dull_Flatworm777 Aug 09 '26
If this is your first programming language, I'll go against the grain a bit and recommend Ruby first. It's a great beginner language. Rust is not.
22
u/Serializedrequests Aug 09 '26
It's not a religion. Start with what you're most excited about.
13
u/anykeyh Aug 09 '26
Ruby. Less hassle for hobbying around, believe me. Remain powerful for almost anything, as long as you don't require performance such as making a complex game or heavy data processing.
8
u/HashDefTrueFalse Aug 09 '26
It really doesn't matter and you can switch at any time. Rust is more involved for the average hobbyist, IMO. You can build all the things you list with either language. You could even write different parts in each for fun.
8
u/jerrygreenest1 Aug 09 '26
It’s like asking an artist, whether to pick pencils or brushes to draw. They’re completely different. It’s up to what you want.
Ruby has the best-in-class OOP model, which you won’t see in any other language to this level.
Does that mean Ruby is the best language? No. Because not everything comes down to OOP, and in fact there is becoming more popular of an opinion that OOP as a whole concept, sucks. So being best at something that sucks, isn’t entirely cool.
The only really common thing they have is that they’re both programming languages, they’re both start with R and both have 4 letters in the name. Pretty much everything else is different.
For example Rust is compiled language and Ruby is interpreted. Ruby as a language by itself isn’t as bad as Python but many will consider it inferior to many other languages, just like Python, simply because it’s interpreted.
Rust? Just a very different beast and it’s more so for people coming from C/C++ rather than to compare it with interpreted languages like Ruby or Python which are different weight class.
With the goals that you listed, take a look at Go, it’s great for your goals and is kinda good.
4
u/_acmwq Aug 09 '26
In fact, you answered your own question "I want to create simple applications and have fun" and this is 100% ruby
1
u/Guybrush1973 Aug 09 '26
I dunno much of ruby, but rust is one of the most complex lang out there for this scope, for an hobby I would definitely suggest to stay sticky on python, the simplest one, that will give so more joy in the close run. Rust is for hard coder.
The other cousin for web-dev is PHP, quite simpler, effective and supported.
1
u/pVom Aug 10 '26
For a hobbyist? Ruby every day.
It's probably the best designed language, it's incredibly consistent, easy to write, easy to debug.
Ruby on Rails is building a web app on easy mode, it's still way better than the alternatives that superceded it IMO.
When you're learning I think it's important to quickly get from the tutorial stage to building something you can show your mother. Ruby is still probably the best at that.
Rust is a great language too but it's doing it in hard mode. What it's great at you don't really need. It will also be much easier to pick up later once you have a solid foundation of the programming fundamentals and a language under your belt.
I'd throw JavaScript as a potential starter, if you're doing web you need to know it anyway, there's no avoiding it really. It's incredibly versatile and can do everything you need. There's certainly quirks, fundamentally it's not as well designed as Ruby (or rust for that matter), but if you want one language to do it all, JavaScript is the only answer.
3
u/catbrane Aug 09 '26
Ruby is great fun to program in, it's extremely expressive and you can do some wonderfully nutty things. It has terrific support for metaprogramming, meaning you can make a library that defines a new programming language that sits inside ruby itself.
fisk is the canonical example:
https://github.com/tenderlove/fisk
It's an x86 assembler written in Ruby. Using it, you can make code like this:
That looks like x86 assembly, right? It's actually a pure ruby program you can run to build a binary that you can execute. Amazing!
I have an axidraw pen plotter. Here's a ruby script that draws a fractal that looks like a bunch of flowers:
https://github.com/jcupitt/axidraw/blob/master/turtle2/plant.rb
That uses this little turtle graphics class for
move,penup, etc.:https://github.com/jcupitt/axidraw/blob/master/turtle2/turtle.rb
Which in turn renders to SVG:
https://github.com/jcupitt/axidraw/blob/master/turtle2/drawing.svg
The downside of Ruby is that it's probably too complex. The language has five (5!! FIVE) different types of lambda, for example.
As you say, Rust is less fun and more disciplined. But performance and reliability are fantastic.
1
u/Biliunas Aug 09 '26
Why can’t you do both? Not in the same project obviously, but make a beginner project in one and the other. That way, you’ll feel the differences sharply and feel what’s better for the next one.
1
u/uptimefordays Aug 09 '26
I would look at formal structured education rather than stumbling through languages. There are a bunch of solid online courses for learning programming concepts which will make learning syntax of various languages easier.
1
u/No-Dentist-1645 Aug 09 '26
Honestly neither? Both are pretty purpose-specific programming languages. I would recommend either you try to learn Python again or start off by learning a bit of C for the basics and then move to Rust
1
u/OccasionThin7697 Aug 09 '26
Gleam
1
u/ledatherockband_ Aug 09 '26
i like ruby. i've done only a smidge of rust. it was fun.
i think you should figure out what you want to first build and start from there.
perhaps you can a radio station with ruby and rust? i was gonna do something similar with ruby and C. ruby can handle the web app and rust can handle streaming audio. im building it for fun so you won't be 'stealing' my idea idea lol
1
u/PartyParrotGames Aug 09 '26
For hobbyist learning I would highly recommend Ruby over Rust. I'm actually a heavy Rust programmer, but it's not beginner friendly. Ruby is. Ruby or Python are what I'd recommend for learning and hobby work, especially if you're going to be doing web an rest apis.
1
u/ligma_then_sugma Aug 10 '26
they're different tools for different jobs
1
u/Dismal_Ordinary_8643 Aug 10 '26
Actually Ruby is a really niche language (just check https://www.tiobe.com/tiobe-index/) and there is very-very small probaility that you could use in professionl carrier except fo some boring legacy support projects.
Python is really great thing to start diving into programming and from other side it is most popular langauge in Open Source.
And as second advice - when you clearly get an idea of metaclasses in Python - switch to Rust.
Rust is good guy but defnitely not a first language to learn CS and algorithms (think about linked list, for example).
Good luck!
1
u/countsachot Aug 10 '26
I like both of those languages.
Ruby is easier to start imo, and you can get robust web applications running extremely quickly with Ruby on Rails.
You'll learn more about computing in general from Rust, since it's a bit closer to the hardware memory.
Both languages have terrific documention.
1
u/spinwizard69 Aug 11 '26
You have a spread of interest that are not going to have a one language solution.
So what I'm going to suggest is finding and following a good Computer Science (CS) program, Ideally one that starts with either C or C++. Any decent CS program will focus on teaching concepts, the language just needs to be low level enough to actually allow clear expression of the concepts you need to learn.
As for languages you are looking at, RUBY in my opinion is a dead language that would be a waste of time to learn. RUST is interesting but I look at it as language that arrived to late to the dance and will not have a partner. At least not a partner that that can cover all needs well.
As for targeting a platform, that is going to depend upon the platform. For example on an Apple device you will need to know Swift. Android has its own system programming language, Kotlin being one and on Windows I have no idea. In other words the platform can dictate the language
1
u/Cezabaz_Samid674 Aug 15 '26
honestly if you're just doing hobby stuff, go with whatever excites you more right now, Ruby's gonna be way more forgiving if you hit a wall, but Rust'll teach you stuff about how computers actually work that Ruby glosses over.
1
u/StraightGuy1108 Aug 09 '26
Rust. Its type system is subperb and it has great FP support.
0
u/Commercial-Big-9824 Aug 09 '26
rust
-1
u/LanceMain_No69 Aug 09 '26
Rust, ruby is more niche a language, with dwindling usage.