←back to thread

517 points bkolobara | 1 comments | | HN request time: 0s | source
Show context
jaccola ◴[] No.45043733[source]
I would love to see a web app with an interface where I select two programming languages and it shows me a really clean snippet of code in language A and says "Look how terribly hard and unclean this is to achieve in language B". (and then you could reverse to see where B outshines A).

Languages are a collection of tradeoffs so I'm pretty sure you could find examples for every two languages in existence. It also makes these kinds of comparisons ~useless.

replies(3): >>45044183 #>>45044315 #>>45045969 #
prerok ◴[] No.45044315[source]
For one, snippets is exactly where you don't get good language comparisons.

For example, python is AFAIK the lead language to get something done quickly. At least as per AoC leaderboards. It's a horrible language to have in production though (experienced it with 700k+ LOC).

Rust is also ok to do for AoC, but you will (based on stats I saw) need about 2x time to implement. Which in production software is definitely worth it, because of less cost in fixing stupid mistakes, but a code snippet will not show you that.

replies(1): >>45047515 #
1. munchler ◴[] No.45047515[source]
If I might tweak your point a bit: Snippets are fine for showing language differences when programming in the small, but not for programming in the large.

https://en.wikipedia.org/wiki/Programming_in_the_large_and_p...