10 ms·
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 s
by Mateon1 8y 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.
- sethammons 8y agoI 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.
- sixhobbits 8y agoThe "What is an acronym really and when should it be capitalised" debate is grey enough that it's easier to consistently use RemoteHttpIpAddr
- lern_too_spel 8y agoNot capitalizing the entire acronym is the convention in modern Java and C#. https://google.github.io/styleguide/javaguide.html#s5.3-camel-case https://google.github.io/styleguide/javaguide.html#s5.3-came... https://docs.microsoft.com/en-us/previous-versions/ms182249%28v%3dvs.80%29 https://docs.microsoft.com/en-us/previous-versions/ms182249%...
- renox 8y agoI 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.