Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Ruby has the worst, most complex syntax I have ever used.


Funny, it has the best, most complex syntax I have ever used.

I don't say this to be reductive. I believe there are two ways to approach a programming language: either from the formally-correct, highly-specified point of view; or from the communication and linguistics point of view. Ruby has a terrifying formal syntax precisely so that it can be extremely comfortable if you can get yourself to ignore the formality.

The flexibility fits my brain extremely well, and most of the time the theoretical syntactic complexity just isn't an issue.


wow lol. Des gustibus non-est disputandum.

i code in go these days. i have done perl and java and some others, started with c, did a bit of python along the way. ruby was always my favorite language. so expressive, so easy to be clear while being terse. i've spent months of my life shortening (my own) verbose ruby code. i switched to go only because of the execution speed and the compilation, a few years back the comparison was not even close. i don't know if i would like to go back to dynamic language... but i found ruby to be such a beautiful language.

p.s. this was big when i was leaving ruby: https://rubocop.org/ maybe there is a replacement now, but maybe it would have changed your view.


Rubocop is still important; a lot of tooling relies on it, such that many developers may not know they're using Rubocop.


The gustibus is unarguable indeed, but calling it “complex” is definitely one of the takes of all time.


Many languages look similar, and familiarity feels simple. Ruby however has a lot of idioms fairly unique to the language, and what is different is mistaken for complexity.

I'd call promises in Javascript complex. A block is Ruby isn't complex, it's just weird if you're new to the language.


I used Ruby in the past and I found the syntax not that complex. What other language do you find syntaxically less complex?


Go


Ruby is practically the pseudocode they teach in schools. Which is selected for it's intuitive and simple nature.


Worst maybe, you definitely don’t have to like it. Difficult to parse, maybe, some things can look similar to other things (blocks and Hashes), but complex from to POV of the programmer? Not really.


What do you consider to be the best?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: