
Rosetta Code - bananacurve
http://rosettacode.org/wiki/Rosetta_Code
======
infruset
I think this is a very good way to get a quick idea of how a new language
works. No theory, no blabla, just the code in a language you know well side by
side with the new one.

It actually works well with spoken languages: I've done that by buying the
same book in my native language and a new one for which I know only the
basics, with great success (and perseverance).

~~~
EdwardCoffin
Your method of learning spoken languages is pretty much the same one that
James Murray [1], the editor of the Oxford English Dictionary [2], used to
learn new languages, which he did many times. He used translations of the
bible.

[1]
[http://en.wikipedia.org/wiki/James_Murray_(lexicographer)](http://en.wikipedia.org/wiki/James_Murray_\(lexicographer\))
[2]
[http://en.wikipedia.org/wiki/Oxford_English_Dictionary](http://en.wikipedia.org/wiki/Oxford_English_Dictionary)

------
DSpinellis
Rosetta Code proved very useful in an experiment to see how typos affect code
written in various programming languages
[http://www.spinellis.gr/blog/20121205/](http://www.spinellis.gr/blog/20121205/).

~~~
lazyjones
This is interesting and helpful (provided that the fuzzing does not have some
language bias), I would like to see more languages in that list though - for
example, Go (it should do very well).

------
jokoon
Greatly helped me understanding huffman.

The thing I find most interesting about rosetta code, is not the quantity of
languages, but the actual algorithms which are used. There are many great
algorithms out there who can be done in very short bits of code, which are
great for educational purposes.

------
flavor8
It would be better if the solutions were vetted to be like for like. For
example in
[http://rosettacode.org/wiki/99_Bottles_of_Beer](http://rosettacode.org/wiki/99_Bottles_of_Beer),
some of the solutions add special logic for handling case 1 (singular) and 0
(go to the store), while other solutions do not (arguably correctly, since the
spec didn't request it).

Having different solutions implement different algorithms doesn't really help
somebody just trying to get a sense of the language.

------
jds375
I've been using this site for quite a while when I first made my jump from OO
and imperative programming to functional. The side-by-side comparison was very
helpful. They also have code for just a ton of algorithms in general.

------
beefman
There is also [http://en.literateprograms.org](http://en.literateprograms.org)

------
cordite
I contributed to the RREF implementation when I was in high school on here for
PHP.

------
danso
This has been a cool resource, but its comparisons of tasks can be profoundly
misleading to novices...not intentionally, just because novices don't know how
to really judge things. Take, for example, its section on Web scraping:

[http://rosettacode.org/wiki/Web_scraping](http://rosettacode.org/wiki/Web_scraping)

First of all, web scraping is a complex task. Not just at the low-level code,
but conceptually...web scraping means different things to different people and
this shows up quite frequently even in HN discussions.

In any case, the Rosetta example does kind of the right thing by limiting it
to a very simple operation...but even the operation itself is misleading
(parsing HTML with regexes?). And even in this idealized operation, you have
very different opinions on what it entails. The Ruby one looks correct to me,
and it looks very concise compared to other languages, but only because,
unlike the CoffeeScript example, there is no error handling.

The real problem is that when you're a beginner, you have no concept of how
programming is best done in small steps...Web scraping is simply a chaining of
much smaller steps, such as string manipulation, parsing, options setting,
etc. It's not a "feature" of a language, yet if you were to make a judgment on
Rosetta (and who else but a beginner would really use Rosetta to compare
languages by webscraping), you're going to have an unhelpful perception of
programming languages and programming in general.

That said, it's a great resource when the task is low-level and well-defined.
But what that actually means obviously differs for people and languages.
Hence, opinionated frameworks and the like

~~~
phazmatis
As long as people go to that site with the intention to learn languages, and
not learn the concepts involved, they'll quickly realize that like wikipedia,
the quality of the submissions is sometimes lacking. In fact, a lot of pages
have multiple versions of the same program, say, in ruby, with an imperative
style and a functional style, or using different language features and degrees
of idomatic...ness.

