Comparing 10 programming languages. I built the same app in all of them.

preview_player
Показать описание
Many modern programming languages have some great features like null safety, exhaustive switch statements, error handling, strong type systems, immutability, great tooling and good readability and write-ability.

I couldn't decide which language I preferred so I made a TCP server that does some basic file processing in all of them. Using no dependencies where applicable.

I did this using Rust, Go (or Golang), Crystal, Kotlin, Julia, Zig, Nim, Gleam, Swift and Dart.

Just for fun, I gave each language a 1 to 5 score in the categories of tooling, safety, readability and ergonomics.

Just btw this is an incredibly biased video so please don't take anything personally.
Рекомендации по теме
Комментарии
Автор

"It is a skill issue but an issue nonetheless."

ridwanulhaque
Автор

Timestamps for folks:
1:00 Golang
3:25 Crystal
5:47 Kotlin
7:33 Swift
9:28 Zig
11:38 Gleam
14:07 Nim
15:30 Dart
16:50 Julia
18:01 Rust

JosephCatrambone
Автор

I use Nim at work for exactly a kind of use-case it excels in: Fast native-compiled statically-linked data processing that needs to be portable to embedded platforms (my giant program compiles as-is on ARM using musl-libc), with ergonomic Pythonic syntax that ensures you don’t need to worry about memory issues. It can be best described as either: Very fast native-compiled Python, or extremely, unrecognizably ergonomic C++. Take your pick.

nERVEcenter
Автор

can't wait to see this when zig is at 1.0+ like the other languages on the list.

EightSixx
Автор

Nim starts getting good when you look into metaprogramming. See some of the DSL libraries like Jester or HappyX. Also its ability to compile into C, C++, or JS makes it good for pretty much any domain.

Also note Nim's memory management model nowadays isnt really a traditional GC, but the memory is automatically managed at compiletime.

sp.n
Автор

Great video! I would like to see a follow-up video analyzing Elixir, F#, Haskell, PureScript, Clojure, and OCaml.

billygnosis
Автор

As zig is pre-1.0, it moves very quickly and the LSP targets the nightly version so it probably didn't work for 0.11. Once it hits 1.0, the idea is to not change the language much and things will settle down a bit. Sorry you had a bad experience with Zig. It really is a great language. If you ever try again, use the nightly!

bjbboy
Автор

Very agreeable takes, thanks for your efforts!

virusblitz
Автор

Julia and Nim, such wonderful but underrated languages. Both in my top 3!

blaisepascal
Автор

You do an excellent job. All that was left to do was take into account the quantity and maturity of the library ecosystem.

lucasmsoares
Автор

My job literally involves Java 8 and JavaScript... I got called out so hard

Sike! We use more and more Rust now because of me >:D

Speykious
Автор

I like Dart the most! It has such clean and logical language features, it just feels nice to write! It doesn't have stupid pitfalls and shortcommings. Also, since it has a big Company behind it, it evolvs very rapidly and gets good improvenents regularly! Since version 3 it got big improvements on the functional side, with pattern matching and exhaustive switch statements. And it has null safety since version 2.

dampfwatze
Автор

Thanks for taking the time to do all this coding and evaluation. It's very nice to see the implementation in diff. languages. IMHO, Rust code is the most unreadable, by far.

CristianMolina
Автор

Love ur refreshing take. Very solid video. Thank u very much. I enjoyed this very much. U helped cut thru the type and showed me the warts of zig nim etc

generalyoutubewatching
Автор

Nim also supports checked exceptions btw. And the default GC is refcounting like swift.

bmatt
Автор

Nice comparison! Good job. Try also OCaml next time:) I'm sure you will enjoy it as it's like a rust with GC.

Sel
Автор

9:08 Sad truth😔I feel Swift is such a beautiful language with so much potential. And while it is open-source and Apple is doing something, it's not that widely adopted because:
1) Still needs a good cross-platform IDE
2) Apple Documentation is terrible
3) It lacks APIs for so many general-purpose things

danstoian
Автор

I would have added performance as a criteria.

Vogon
Автор

Very interesting video. Just an idea for next similar ones: you should also compare these with "classical" languages that everyone has to use at everyday work such as Java, JavaScript, Python or C#... This would give the insight about the language evolution from the classics to the modern ones.

Btw. I am a Kotlin fan. As I do not mind using JetBrains tooling (which is perfect!) I would give it much more points in tooling category which would make it almost a winner. :)

I was surprised by Gleam, I have never heard of it... but I will definitely find out more.

vladimirkraus
Автор

I’ve working with Bun and I am really liking it. The tooling is awesome and not require external dependencies do to the basics. The websocket module is awesome and easy to use

Andrey_Hz