r/AskProgramming • • May 03 '26

Architecture When is C better than Rust?

I've seen a lot of people saying that Rust = C but more secure. Is that true? Is there any catch or something? If you've used both of these programming languages, what was your experience with each? Which ones did you prefer?

I am writing this because I still don't know in which language should I code my backend for a website, and I don't want to mess things up. I am choosing low level because I want performance and low RAM usage + I am more familiar with low level languages.

TLDR; When do you think I should rather use C over Rust and vice versa?

1 Upvotes

91 comments sorted by

View all comments

Show parent comment

1

u/Objective-Farmer4183 May 03 '26

Then what should I code my backend in?

2

u/Gnaxe May 04 '26

Clojure. Seriously. It won't be as performant as Rust, but the JVM is very optimized, and you'll be far more productive.

1

u/themule71 May 05 '26

Today we run web backends in high level languages even on microcontrollers.

So unless you're really tight on resources i.e. a 40 yo PC, there's no point in not using a modern web framework, be it in python, PHP, js. I've stopped writing web apps in C in '97. And I was being stubborn.