top | item 18550295

(no title)

Mateon1 | 7 years ago

I went back and forth, both ways. I started out in Python with snake_case identifiers, then moved to Javascript with camelCase, and now I mostly use Rust with snake_case for names and UpperCamelCase for types.

I don't find either style better than the other, the only time I notice anything is when I switch between style conventions (e.g. switch between JS and Rust or C++), because I need to break the habit of typing one way rather than the other.

Still, I find readability of the two styles pretty much identical at all times once you get used to both.

discuss

order

sethammons|7 years ago

I mostly find the readability the same, except for acronyms in the middle. RemoteHTTPIPAddr vs remote_http_ip_addr. I prefer the latter, but my go-to language these days encourages the former.

renox|7 years ago

I work in telecoms where there are so many acronyms that snakeCase is really painful (but we still use it). As for your second example, why not remote_HTTP_IP_addr ? Even more readable IMHO.

sixhobbits|7 years ago

The "What is an acronym really and when should it be capitalised" debate is grey enough that it's easier to consistently use

RemoteHttpIpAddr