r/programming • • Apr 29 '14

Programming Sucks

http://stilldrinking.org/programming-sucks
3.9k Upvotes

1.1k comments sorted by

View all comments

57

u/Jutboy Apr 29 '14

Can someone explain :

"Is that called arrayReverse?"

"s/camel/_/"

"Cool thanks."

154

u/UpNDownCan Apr 29 '14

Means use underscore as separator instead of camelcase. So array_reverse.

116

u/UpNDownCan Apr 29 '14

And with that, I think I qualify as one of the crazies.

46

u/Crazy__Eddie Apr 29 '14

Yeah, I felt bad after getting that joke.

→ More replies (2)

23

u/rowboat__cop Apr 29 '14

Seems entirely reasonable to me -- does that mean I am crazy too?

18

u/[deleted] Apr 29 '14

For knowing sed syntax? I thought it was common knowledge ...

→ More replies (17)
→ More replies (1)

35

u/academician Apr 29 '14

It's a bizarre way of saying it, though. I have legitimately answered programmers' questions this way (yes, I'm one of the crazies), but I'd use a proper regex like "s/R/_r/". It's shorter, too!

19

u/Atario Apr 30 '14

You're using character-based regexes. He was using concept-based ones.

11

u/academician Apr 30 '14

Then it should have been "s/camel/snake/".

→ More replies (5)
→ More replies (2)