4 ms·
Leads to "How can I write a switch statement in Ruby?"
by eliot_sykes 13y ago
Leads to "How can I write a switch statement in Ruby?"
- izietto 13y agoYes, it seems to me quite ironic (and weird) that the most voted Ruby question on StackOverflow asks for how to write a switch!
- dasil003 13y agoWhat's ironic about it? What would you expect to be the most voted ruby question?
- izietto 13y agoSurely not a question which could be easily answered with a LMGTFY like this http://lmgtfy.com/?q=switch+statement+in+ruby http://lmgtfy.com/?q=switch+statement+in+ruby
- chrismonsanto 13y agoThat's exactly why it would be the most voted question. It's a common thing to Google, and the Google search leads to the StackOverflow page linked, which leads to lots of upvotes.
- izietto 13y agoYes, but if I want informations about Ruby switch statements it means you are a newbie that should refer to a whole language syntax reference; you could say that Ruby has not an official language syntax reference (this is the most "official": http://web.njit.edu/all_topics/Prog_Lang_Docs/html/ruby/syntax.html http://web.njit.edu/all_topics/Prog_Lang_Docs/html/ruby/synt... ) so newbies are forced to google for syntax explanations, which is true, but it seems too little to make it the first Ruby question. And I think Ruby management has its negligence; it's weird that a so popular and mature language has so much lack of informations about its behaviour.
- sebastialonso 13y agoThat question was...unexpected to me, to say the least. I was expecting something obscure, maybe related to meta programming, certainly not something about flow structures!
- dasil003 13y agoYou were expecting something obscure to be the most voted question?
- pgsandstrom 13y agoJust compare it to other languages, there is a clear difference. Java: http://stackoverflow.com/questions/11227809/why-is-processing-a-sorted-array-faster-than-an-unsorted-array http://stackoverflow.com/questions/11227809/why-is-processin... Php: http://stackoverflow.com/questions/60174/how-can-i-prevent-sql-injection-in-php http://stackoverflow.com/questions/60174/how-can-i-prevent-s... Javascript: http://stackoverflow.com/questions/111102/how-do-javascript-closures-work http://stackoverflow.com/questions/111102/how-do-javascript-...
- Shish2k 13y agoLooking at the top few questions for several languages, I note some trends: Ruby, Python, Javascript: unique-ish language features Java: general comp-sci corner cases C, C++: what does this obscure operator mean Erlang, Haskell, Node: how to get started Go: how to live without features that were intentionally not included PHP: How to avoid the security pitfalls that the standard library encourages Seems about right... (Though I'm surprised to see Node alongside Erlang and Haskell in terms of people not knowing where to start)